EasyManua.ls Logo

Laser 128 - MID

Laser 128
255 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
3.34
MID$
Purpose:
BASIC COMMANDS AND
STATEMENTS
To
return
a
specific
number
of
characters
from
within
a
given
string.
Format:
MID$
(
X$
,
i[.j]}
Comments:
Both
i
and
j
must
be
between
I
and
255. MID$
returns
j
characters
of
string
X$
starting
from
the
ith
character.
Example:
If
j is
not
specified,
then
MID$
has
the
same
effect
as
the
RIGHT$
( X$,
i)
function.
Al
so,
if
i
is
greater
than
LEN(X$),
then
a
null
string
is
returned.
] 10
X$
=
"Program
in"
] 20 Y$ = "
Fortran
Basic
Cobol"
] 30
PRINT
X$;
MID$
(Y$, 11, 8)
]RUN
]
Program
in
Ba
sic
11-65

Table of Contents