Please note, this is a STATIC archive of website www.tutorialspoint.com from 11 May 2019, cach3.com does not collect or store any user information, there is no "phishing" involved.
Tutorialspoint

Array example

/* REXX ----------------------------------------------
* The compond variable a. implements an array
* By convention, a.0 contains the number of elements
*---------------------------------------------------*/
SAY ARG "arg"
PARSE ARG input
SAY input "ssad"
PULL Arg adjective lohlo
SAY adjective "fdsbsbfsfb"
SAY lohlo "fvsfv"
SAY RANDOM() 


PARSE ARG token.1 token.2 
DO i=1 TO 2
   SAY "Token" i "is:" token.i
END

a.=0                   /* initialize the "array" */
call store 'apple'
Call store 'orange'
Say 'There are' a.0 'elements in the array:'
Do i=1 To a.0
  Say 'Element' i':' a.i
  End
Exit


store: Procedure Expose a.
say arg()
z=a.0+1
a.z=arg(1)
a.0=z
Return

Advertisements
Loading...

We use cookies to provide and improve our services. By using our site, you consent to our Cookies Policy.