in reply to Re^3: Valid Numbers or decimals
in thread Valid Numbers or decimals

How about:
#!/usr/bin/perl my @numbers = (0, 3.14, 5 , 4_000_000, 3_000.42, "any strings 234 "); print "@numbers\n"; my @numgoods = grep{/^(\d*[\._]?\d+)$/ } @numbers; print "@numgoods\n";

I'm not really a human, but I play one on earth. flash japh