In smart BASIC you can use short notation for math operations if they are using the same variable. For example strings:
Code: Select all
A = A + 1
B = B * A
M (K) = M (K) / 3
Code: Select all
A += 1
B *= A
M (K) /= 3
Any numeric variable or array value is zero by default until it is changed. Similarly, any unused string value is an empty string "".
Such double-word commands as END IF or END DEF can be written without space between words: ENDIF, ENDDEF.
Labels can be not only literal as
Code: Select all
LOOP: GOTO LOOP
Code: Select all
10 GOTO 10
Code: Select all
'single-line comment
/* multi-line
comment */
Code: Select all
IF A = B THEN GOTO 1
Code: Select all
IF A = B THEN 1
Code: Select all
PRINT "before subroutine"
GOSUB SUBPROG
PRINT "after subroutine"
END
SUBPROG:
PRINT "inside subroutine"
RETURN
Code: Select all
PRINT "before subroutine"
GOSUB 1
PRINT "after subroutine"
END
1 PRINT "inside subroutine"
RETURN
Code: Select all
A = 1 ! B = 2 ! PRINT A + B
Carefully read "Basics" section in documentation, test those smart BASIC features which are interesting to you, and ask questions on Forum if something will remain unclear.