<s>
SDS	B-Language
BASIC	I-Language
,	O
also	O
known	O
as	O
CP-V	B-Operating_System
BASIC	O
,	O
Batch	O
BASIC	O
or	O
Sigma	O
BASIC	O
depending	O
on	O
the	O
version	O
,	O
is	O
a	O
BASIC	O
programming	B-Language
language	I-Language
compiler	I-Language
for	O
Scientific	O
Data	O
Systems	O
's	O
(	O
SDS	O
)	O
Sigma	B-Device
series	I-Device
mainframe	B-Architecture
computers	I-Architecture
,	O
originally	O
released	O
in	O
1967	O
.	O
</s>
<s>
The	O
original	O
versions	O
did	O
not	O
include	O
support	O
for	O
string	O
variables	O
,	O
although	O
this	O
was	O
added	O
for	O
the	O
version	O
running	O
under	O
the	O
CP-V	B-Operating_System
operating	I-Operating_System
system	I-Operating_System
when	O
it	O
was	O
released	O
in	O
1971	O
.	O
</s>
<s>
The	O
string	O
library	O
allowed	O
manipulation	O
of	O
strings	O
using	O
array	O
slicing	O
syntax	O
,	O
similar	O
to	O
the	O
system	O
found	O
in	O
HP	B-Language
Time-Shared	I-Language
BASIC	I-Language
and	O
a	O
number	O
of	O
microcomputer	B-Architecture
BASICs	O
like	O
Integer	B-Language
BASIC	I-Language
and	O
Atari	B-Language
BASIC	I-Language
.	O
</s>
<s>
This	O
style	O
of	O
string	O
manipulation	O
differs	O
from	O
the	O
model	O
introduced	O
in	O
DEC	O
's	O
BASIC-PLUS	B-Language
,	O
which	O
used	O
string	O
functions	O
.	O
</s>
<s>
Altair	B-Language
BASIC	I-Language
was	O
patterned	O
on	O
BASIC-PLUS	B-Language
,	O
and	O
this	O
style	O
became	O
the	O
de	O
facto	O
standard	O
after	O
the	O
cross-platform	O
version	O
,	O
Microsoft	B-Language
BASIC	I-Language
,	O
became	O
almost	O
universal	O
during	O
the	O
home	O
computer	O
era	O
.	O
</s>
<s>
SDS	B-Language
BASIC	I-Language
is	O
historically	O
notable	O
as	O
the	O
platform	O
on	O
which	O
the	O
original	O
Star	B-Application
Trek	I-Application
computer	O
game	O
was	O
written	O
in	O
the	O
summer	O
of	O
1971	O
.	O
</s>
<s>
In	O
keeping	O
with	O
the	O
original	O
Dartmouth	B-Language
BASIC	I-Language
model	O
,	O
and	O
in	O
common	O
with	O
most	O
mainframe-based	O
BASICs	O
,	O
SDS	B-Language
BASIC	I-Language
was	O
a	O
compiler	B-Language
,	O
not	O
an	O
interpreter	O
,	O
and	O
used	O
separate	O
but	O
tightly	O
integrated	O
tools	O
for	O
editing	O
and	O
running	O
.	O
</s>
<s>
Because	O
SDS	O
was	O
a	O
compiler	B-Language
,	O
and	O
the	O
user	O
's	O
source	O
code	O
was	O
stored	O
separately	O
,	O
it	O
preserved	O
leading	O
spaces	O
in	O
the	O
code	O
.	O
</s>
<s>
The	O
early	O
versions	O
of	O
SDS	B-Language
BASIC	I-Language
,	O
sometimes	O
known	O
as	O
Batch	O
BASIC	O
or	O
BTM	O
BASIC	O
,	O
did	O
not	O
support	O
string	O
variables	O
.	O
</s>
<s>
However	O
,	O
string	O
values	O
could	O
be	O
assigned	O
to	O
numeric	O
variables	O
which	O
could	O
store	O
six	O
characters	O
as	O
their	O
EBCDIC	B-Language
numeric	O
values	O
.	O
</s>
<s>
The	O
later	O
CP-V	B-Operating_System
BASIC	O
added	O
true	O
string	O
variables	O
containing	O
up	O
to	O
132	O
characters	O
that	O
could	O
be	O
indicated	O
with	O
a	O
trailing	O
dollar	O
sign	O
,	O
,	O
or	O
uncommonly	O
,	O
a	O
leading	O
$	O
and	O
are	O
equivalent	O
.	O
</s>
<s>
Internally	O
,	O
CP-V	B-Operating_System
used	O
a	O
fixed-length	O
string	O
layout	O
consisting	O
of	O
an	O
array	O
of	O
bytes	O
that	O
could	O
not	O
be	O
changed	O
in	O
size	O
at	O
runtime	O
.	O
</s>
<s>
It	O
contrasts	O
with	O
the	O
DEC/Microsoft	O
style	O
,	O
where	O
strings	O
were	O
dynamically	O
allocated	O
on	O
a	O
heap	B-Application
.	O
</s>
<s>
Because	O
strings	O
in	O
CP-V	B-Operating_System
did	O
not	O
present	O
themselves	O
publicly	O
as	O
arrays	O
of	O
characters	O
,	O
the	O
slicing	O
syntax	O
was	O
not	O
based	O
on	O
array	O
syntax	O
.	O
</s>
<s>
This	O
meant	O
CP-V	B-Operating_System
also	O
allowed	O
the	O
construction	O
of	O
arrays	O
of	O
strings	O
,	O
something	O
dialects	O
like	O
HP	O
and	O
Atari	O
lacked	O
because	O
they	O
used	O
array	O
notation	O
for	O
slicing	O
.	O
</s>
<s>
CP-V	B-Operating_System
also	O
includes	O
the	O
CHANGE	O
command	O
from	O
Dartmouth	B-Language
BASIC	I-Language
,	O
which	O
converts	O
a	O
string	O
into	O
a	O
series	O
of	O
EBCDIC	B-Language
numeric	O
values	O
and	O
places	O
them	O
into	O
a	O
numeric	O
array	O
:	O
</s>
<s>
B	O
will	O
now	O
contain	O
a	O
series	O
of	O
numbers	O
corresponding	O
to	O
the	O
EBCDIC	B-Language
values	O
for	O
each	O
character	O
.	O
</s>
<s>
Later	O
versions	O
of	O
Dartmouth	B-Language
BASIC	I-Language
included	O
a	O
suite	O
of	O
MAT	O
commands	O
that	O
allowed	O
operations	O
on	O
entire	O
arrays	O
(	O
matrices	B-Architecture
)	O
with	O
a	O
single	O
statement	O
.	O
</s>
<s>
These	O
were	O
also	O
available	O
in	O
SDS	B-Language
BASIC	I-Language
.	O
</s>
