Download Print this page

Sharp MZ-1X10 Instruction Manual page 7

Advertisement

Some s1mple
examples of BASIC programs
us1ng
the MSIN
statement are
shown
low
.
Example
1
Th1s
example
d1splays
a
...
.. mark
at
the
screen
pos1t1on
corresponding
to
the
coordinates at wh1ch the
sw1tch
on
the "2" s1de
IS
pressed
after
mov1ng the
:
mouse
When
th1s
program
IS
executed.
execution
wa1ts
at line
20
unt1l
coord1nates
are
1nput.
1
0
CHANGE
DISP
"SON"
20
MSIN
O.O.X.Y
30
CURSOR
X/
S.
Y
/
S.DISP
..
.
..
40
END
Example
2
The
follow1ng
program
performs
six repetitions
of the
operat1on
descn
-
bed
1n
Example 1
.
1
0
CHANGE
DISP "SON"
20
FOR 1=1 TO
6
30
A=X:B=Y
40
MSIN
A.B.X.Y
50
CURSOR
X/
S.Y
/
S'DISP
..
.
..
60
NEXT I
70
END
4

Advertisement

loading