neilsf / XC-BASIC

A compiling BASIC dialect for the Commodore-64
https://xc-basic.net/
MIT License
75 stars 15 forks source link

New array commands #103

Closed neilsf closed 3 years ago

neilsf commented 4 years ago

Some new statements are to be introduced that support working on arrays. Some of them stolen from QB.

ERASE: set all elements to zero UBOUND(): return the highest valid index (upper boundary) of an array SWAP: trades the values of two numerical values or array elements FOREACH ... NEXT: iterate through all elements in an array in a fast and convenient way