I don't know which of these variable length strings are used in Basic, but mainly there are several ways to implement variable arrays (maybe the list is incomplete);
- As you mention: pointer to the next fragment; or actually, it denotes the length of the string (i.e. the number of characters following)
- Same like 1, but the first byte contains the length including the first byte (so the same as one, but the first byte is 1 higher)
- More common in C variable strings: Starting with the characters, and and end-of-string delimiter of a 0 (\0) byte. In the ZX80 the " was used as end-of-string (see quote below).
- The high order bit as end of string flag (see second quote, TinyBasic).
However, I could find one fragment about ZX80 Basic, which uses the " character as string delimiter, see wiki/String_(computer_science):
Using a special byte other than null for terminating strings has
historically appeared in both hardware and software, though sometimes
with a value that was also a printing character. $ was used by many
assembler systems, : used by CDC systems (this character had a value
of zero), and the ZX80 used " since this was the string delimiter
in its BASIC language.
Somewhat similar, "data processing" machines like the IBM 1401 used a
special word mark bit to delimit strings at the left, where the
operation would start at the right. This bit had to be clear in all
other parts of the string. This meant that, while the IBM 1401 had a
seven-bit word, almost no-one ever thought to use this as a feature,
and override the assignment of the seventh bit to (for example) handle
Early microcomputer software relied upon the fact that ASCII codes do
not use the high-order bit, and set it to indicate the end of a
string. It must be reset to 0 prior to output.
See TinyBasic Design, chapter Encoding partly:
In a number of places we have to indicate the end of a string of characters (or else we have to provide for its length somewhere). Commonly, one uses a special character (NUL = OOH for example) to indicate the end. This costs one byte per string but is easy to check. A better way depends upon the fact that ASCII code does not use the high order bit; normally it is used for parity on transmission. We can use it to indicate the end (that is, last character) of a string. When we process the characters we must AND the character with 07FH to scrub off the flag bit.