my $str = '380|Kelley Gibson-White|6|0|85|14.2|3|17|.176|8|8|1.000|'; # Get the name my ($name) = (split /\|/, $str, 3)[1]; # Initialize the first name $name =~ s/(\w)\S*\s+(.*)/$1. $2/; print $name;