1234567
map { $_->[0] = getDate($_->[0]); $_->[2] =~ s/x/y/g; join '|', @$_;}sort { $a->[0] <=> $b->[0] }map { [ split /\|/ ] } @read;