in reply to changing a certain value

just join the values with a comma:

my $new_val= join ',' , @values;