c: b$="OOO...XXX" t=0 k=0 w=0 l: cls r=0 for i=0 to 2 print mid$(b$,i*3+1,3) next i wait 1 if w or t=3 then goto w input a if (a<74)*(a>96) then goto l x=a\10 y=a mod 10 r=(a-50+20*(x>7))*(t=0)*(x-y=3) if t=1 then r=r-36*(a=75 or a=95 or a=84) r=r-14*(a=86) r=r-47*(a=96 or a=85)+11*(k=5)*(a=96)+22*(k=6)*(a=85) r=r-69*(a=74)-11*(k=5)*(a=74) w=1+(a=95) end if r=r-69*(t=2) trace a,r,x,y,t,k r=r*-(r<>22) if r then mid$(b$,y,1)=mid$(b$,x,1) mid$(b$,x,1)="." mid$(b$,r mod 10,1)=mid$(b$,r\10,1) mid$(b$,r\10,1)="." k=y inc t end if goto l w: print"AI WINS" print"PRESS ANY KEY" do wait 1 if inkey$<>"" then goto c loop