Reverse words in a string: Difference between revisions

Content added Content deleted
m (Broke apart a long (multi-sentence) paragraph into simpler/separate declaratives, added whitespace for readability, showed the task's requirement as a separate paragraph.)
(→‎{{header|Perl 6}}: explicit stringification to avoid printing parenthesis)
Line 1,324: Line 1,324:
=={{header|Perl 6}}==
=={{header|Perl 6}}==
We'll read input from stdin
We'll read input from stdin
<lang perl6>say .words.reverse for lines</lang>
<lang perl6>say ~.words.reverse for lines</lang>
{{out}}
{{out}}
<pre>------------ Fire and Ice ----------
<pre>------------ Fire and Ice ----------
Line 1,336: Line 1,336:


----------------------- Robert Frost</pre>
----------------------- Robert Frost</pre>

=={{header|PicoLisp}}==
=={{header|PicoLisp}}==
<lang PicoLisp>
<lang PicoLisp>