[comp.lang.rexx] REXX Parse

RGR05076@NUSVM.BITNET (12/28/87)

I have the following code:
Parse var onepage 1 oneline 81 rest

If I want '1' and '81' to be variables, I can use one of the followings:
1. Interpret 'Parse var onepage' x 'oneline' y 'rest'
2. oneline="SUBSTR"(onepage,x,y-x); rest="SUBSTR"(onepage,y)

My questions are:
1. which is more efficient: 1st method or 2nd method?
2. is there a better (more efficient) method?

SYMSW@NASAGISS.BITNET (Michael S Weiss) (12/28/87)

When you want to use variables as part of a template, enclose
the variable in parens and it will be used that way.  Thusly:

Parse Var onepage (x) oneline (y) rest

Hope this helps,
/msw

----------
Michael S. Weiss
Systems Programmer/Analyst
NASA Goddard Institute for Space Studies