|
Post by tsh73 on Apr 15, 2020 16:21:42 GMT -5
WORD$ saves the day 976 characters
mainwin 105 40:dim s(99,6):p=45:g=99 for c=10 to p s(c,1)=int(rnd(1)*50):s(c,2)=int(rnd(1)*30):s(c,3)=(0.5-rnd(1))*4:s(c,4)=(0.5-rnd(1))*4:if rnd(1)<.5 then s(c,5)=1:s(c,6)=g:f=f+1 next while f>0 for c=10 to p if s(c,5)=1 then s(c,6)=s(c,6)-1:if s(c,6)<=0 then s(c,5)=2:f=f-1 end if s(c,1)=s(c,1)+s(c,3) s(c,2)=s(c,2)+s(c,4) if s(c,1)<1 then s(c,1)=2:s(c,3)=0-s(c,3) if s(c,2)<1 then s(c,2)=1:s(c,4)=0-s(c,4) if s(c,1)>50 then s(c,1)=49:s(c,3)=0-s(c,3) if s(c,2)>30 then s(c,2)=29:s(c,4)=0-s(c,4) next c for c=10 to p:for d=10 to p if c<>d then if int(s(c,1))=int(s(d,1)) and int(s(c,2))=int(s(d,2)) then if s(c,5)=1 and s(d,5)=0 then s(d,5)=1:s(d,6)=g:f=f+1 else if s(d,5)=1 and s(c,5)=0 then s(c,5)=1:s(c,6)=g:f=f+1 end if:end if:end if:end if:next:next r$="":for y=1 to 30:for x=1 to 50 i$="--" for c=10 to p if int(s(c,1))=x and int(s(c,2))=y then i$=word$(c;" XX **",s(c,5)+1) next:r$=r$+i$ next:r$=r$+chr$(13):next cls:print r$;" ";f wend
|
|
|
Post by David Drake on Apr 16, 2020 12:05:24 GMT -5
Very nice!
|
|