my $str = "this is a string"; print $str =~ m/\w+$/g;