|
|
沙发

楼主 |
发表于 2009-9-12 23:17:44
|
只看该作者
Re: sas 强人帮我看看这个怎么写 为什么我怎么写 Y都是错的呢 5555555
[code:33zncy6s]
ships=0;
missiles=0;
do until (missiles>=16);*number of missiles may be presumably more than 16,that should be Okay;
ran=ranuni(0);
missiles+ifn(ran<=0.7,1,ifn(ran<=0.9,2,3));*at last attack, u-boat may need more missiles than number of missiles left,but that still counts;
ships+1;
end;
[/code:33zncy6s]
*i dont have SAS at home thus not able to test it |
|