foreach $item(@sorted){ @new=split(/\s+/,$item); print $new[13]; if($new[13] > $new [10]){ print $item; }