Anonymous user
List rooted trees: Difference between revisions
m
→{{header|REXX}}: added/changed comments.
m (→{{header|REXX}}: added/changed comments.) |
|||
Line 1,371:
start= 2**nn + (2**nn) % 2 /*calculate the starting decimal number*/
if N==1 then start= 2**1 /*treat the start for unity as special.*/
#= 0 /*count of ways to nest bags (so far). */
$= /*string holds possible duplicious strs*/
say /*separate number─of─ways with a blank.*/
say # ' is the number of ways to nest' n "bags." /*stick a fork in it, we're all done. */</lang>
|