my @list= qw(first_string second_string); @list = map((s/_string$// and $_), @list); print @list;