my $string = "something, something, something, this"; my ($lastword) = $string =~ /\s(\S+)$/;