GAME_]
block
was pl.iced
coincides
with
the
position
to
which
the
chicken
moved,
the
screen
displays
"I
WIN,"
indicating
that
the
chicken
has
won.
The
game
is
over.
So,
you
must
foresee
the
possible
movements
of
the
chicken
in
conducting
the
game.
When
you
successfully
catch
the
chicken,
the
screen
displays
"YOU
WIN,"
and
the
program
dis-
plays
the
number
of
blocks
required
to
catch
the
chicken.
The
smaller
the
number,
the
better.
When
the
game
is
over,
the
program
asks
"PLAY
AGAIN?
(Y)."
If
you
wish
to
play
again, press
the
Y key.
OCJITJ!IDEB
Now
the
chicken
is
completely
hemmed
in.
You
can
catch
it
by
keying
in
x=2,y=2.
926
Bytes
lfllllfillllftttffllMtttltllllllllttt1t1tit,t1ftttflllltltltllttl!llflf•litrt1t11itrttt1
■
1ftllllllflllllltf~1lltll!llllfltlltltlllilt8ltlffllltltflflllltltllllllftltltfiflflllftNlltfttllltltfltttl!Mt1tltltflllltllftflltf
1 0
CL
S:
CLE
AF-:
20
LOCATE
0,0:F'RINT"i
+a-·•:FOF-<
J::.=l
TO
5:L
OCATE
0,I:F'RINT"II
■
":NEXT
I
30
LOCATE
v'l,
6:
F'F,Il"T"
a,
40
KL=INT(RNDl-1)*10+2)+INT(RNDC-1)*5+1l/10:IF
<1'.L=HG
l
Ot,
(
f~L
=VG> l
THEN
40
50
Xl=INTlf::t.>
:Yl
0
l0*FRAC<t::Ll
:LOCATE
<Xl-ll
,Yl:F'R
INT"@":
X7=Xl:
Y2==Yl
60
LOCATE
16,
l:F·RINT"
":LOCATE
13,
l:
Il\jf'LJT"X:..-:.";
X :
LOCATE
l 6 ,
.::;
:
F·
R I NT " " :
LOCATE
1 3 ,
~S
: I NF'
UT
" Y = " ; Y
70
rr-·
<CX>ll>OR<X<2>UR(Y>5>0F~(Y<:1))
THEN
60
80
C~0:X3=X2*8-4:Y3~<Y2+1l*B-4
90
f~A=INT<RND(·-1>*4):LOCATE
16,6
100
IF
RA=0
THEN
IF
POINT(X3+8,Y3><>-1
THEN
x2~x2
-tl:
GOTO
l
h'11
1 l 0
IF
hA=
1 THF:N
IF
FCJ
I
NT
(
X3,
Y.3··-8 l <
>--
l THEN
Y2=Y2
-1
:GOTO
160
I
!
i
I
159