Anonymous user
List rooted trees: Difference between revisions
m
→{{header|REXX}}: added wording to the REXX section header about nomenclature used in the program.
(→{{header|REXX}}: added the REXX computer programming language.) |
m (→{{header|REXX}}: added wording to the REXX section header about nomenclature used in the program.) |
||
Line 1,042:
=={{header|REXX}}==
This REXX version uses (internally) a binary string to represent nodes on a tree (<big>'''0'''</big> is a left parenthesis, <big>'''1'''</big> is a right parenthesis). A <big>'''()'''</big> is translated to a <big>'''O'''</big>.
<lang rexx>/*REXX program lists n─node rooted trees (by enumerating all ways of nesting N bato).*/
parse arg N . /*obtain optional argument from the CL.*/
|