echo " one two three four " | awk '{n=split($0,A);S=A[n];{for(i= +n-1;i>0;i--)S=S" "A[i]}}END{print S}'
In reply to Re: Five Ways to Reverse a String of Words (C#, Perl 5, Perl 6, Ruby, Haskell)
by Anonymous Monk
in thread Five Ways to Reverse a String of Words (C#, Perl 5, Perl 6, Ruby, Haskell)
by eyepopslikeamosquito
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |