in reply to How to strip non-numeric values from string?

One way is to use the substitution operator, s///. The following code will only keep digits and the decimal point. You should be able to modify the character class to keep other things, if needed.
use strict; use warnings; for (qw(12.34% 0.05lb 999)) { my $s = $_; $s =~ s/[^\d.]//g; print "$s\n"; } __END__ 12.34 0.05 999