Viper 2.08 User's Guide Page 18

  • Download
  • Add to my manuals
  • Print
  • Page
    / 53
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 17
II\MERT
by
Robert
Lindley
The
vrP
will
seLect
nine
randon
digits,
one
through
nine,
and
dispray
them.
These
numberi
are
not d.uplicated,
6ach
appears
elactry.once.
Th" _object
of
the
game
is to try
to
get
!-our
line
of
digits
in
order
before
the
vrp
puts
its
rini:
in
drdel.
A
possible
starting
display
might
be:
\
If
you press
key
6,
the
new
display
is:
YOU
nm
As
illustrated,
everything
from the
left
end of the
row
to
the
given
key
number
is
inverted. Al-so
the vrp
seleets
its own
inversion.
The
serectioh
made by the vrp
uses
arl
efficient
algorithm,
but
it
does
not take
full advantage
of
natural
ordero
In
the
case
of a tie
--
you
win.
The
program
was
coded
in
a sirnple
straight
forward
mannerr
The
main
program
is first
and
is mostry
cal-rs
to
subroutines
to
do
the
work. There
is
one
r.mique
thing
in the
program,
it uses a
pai-r
of
subroutines
(sgw
ana nnsrn)
to
save
and
restore
the
memory
poj.nter.
Thi-s
neatly
solves
the
problem
of
using one
poi.nter
for both
data
array
reference
and
display
refererlcer
27936
Br5t+
YoU
27936
Br54
ME
INVERT
639?zBr54
972368r54
INVERT6
/z
/il
6z
'/t+
/6
ilB
ile
dc
ilE
L/
T2
*
76
1B
1A
1C
1E
SIART
r
l,lEXT
I
6Ll.//
--
221E
-r
2266
--
T{z
--
22BB
E-
3\6f,
D-
r2:,/g
-r
22DC
F-
23/2
--.
A3F8
--
n26
--
2376
--
A4gg
--
n26
--
12/6
--
Alll
B
--
LISTING
Sigrral
first
pass
of
game
Do
RNDM
Do
SHINV
Do
SHROIU
Do
WINLS
Test
for
start
new
game
Go to
SIARI
Do
GETIN
Do
S}IR
OI/'I
YOUR
Do
DOINV
Do
MYCHS
MINE
Do DOINV
Go to
NEXT
rEMP
RNDMI
?,o\/og .1
B
Page view 17
1 2 ... 13 14 15 16 17 18 19 20 21 22 23 ... 52 53

Comments to this Manuals

No comments