beautypg.com

Getinterval – AMT Datasouth PAL User Manual

Page 115

background image

109

getinterval

example, the following sequences will return all objects or characters starting at index three
through the end of MyArray or MyString.

MyArray dup 3 exch length getinterval
MyString dup 3 exch length getinterval

PAL provides support for negative LengthInt values to allow the programmer to easily access the
end of an array or string. The following examples return the last five objects in MyArray or the last
five characters of MyString.

MyArray 0 -5 getinterval
MyString 0 -5 getinterval