Tree datastructures: Difference between revisions

Content added Content deleted
m (julia example)
m (→‎{{header|Phix}}: separated ouput)
Line 588: Line 588:
golfing
golfing
discourages
discourages
comparison""",
comparison"""

indent = text_to_indent(text),
sequence indent = text_to_indent(text),
nested = indent_to_nested(indent)[1]
nested = indent_to_nested(indent)[1],
n2ichk = nested_to_indent(nested)


puts(1,"Indent form:\n")
puts(1,"Indent form:\n")
Line 596: Line 598:
puts(1,"\nNested form:\n")
puts(1,"\nNested form:\n")
pp(nested,{pp_Nest,8})
pp(nested,{pp_Nest,8})
printf(1,"\nNested to indent:%s\n",{iff(n2ichk==indent?"same":"***ERROR***")})</lang>
sequence r2i = nested_to_indent(nested)
printf(1,"\nNested to indent:%s\n",{iff(r2i==indent?"same":"***ERROR***")})</lang>
{{out}}
{{out}}
<pre>
<pre>