+ (String concatenation)
Syntax
string1 + string2
Description
The concatenation operator takes two string variables and returns a string made of sticking both strings together. As of version 6.08 multiple concatenations per line are supported, and the strings can include string functions such as LEFT, RIGHT, HEX and STR. Also if a constant or integer is used it will be automatically converted to a string, as if it had been enclosed in a STR().
Example
DIM A$(20)
DIM
B$(20)
DIM C$(30)
A$="Hello,"
B$=" World!"
C$=A$+B$
PRINT C$
SLEEP
The output would look like:
Hello, World!
Differences from other BASICs
- PBASIC does not have string function support
- Similar to Visual BASIC