Well, your example doesn't "take all characters except underscores". It substitutes underscores for spaces. If that's what you want, then
$string =~ s/_/ /g;
should work.
davis
Kids, you tried your hardest, and you failed miserably. The lesson is: Never try.