use strict; while (<DATA>) { print ">", trim($_), "<\n"; } sub trim { my ($text) = @_; $text =~ s/^\s+|\s+$//g; #remove leading/trailing whitespace return $text; } __DATA__ Cowboy Bebop Bubblegum Crisis Big O Dragonball Z
In reply to Re: split every second word
by Art_XIV
in thread split every second word
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |