Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
Hey i have data which looks like @data=("conteent" , , , ,25.36,36.36,85.1,.....) . So i want a if statement whose block is accessed only when numeric part comes. Point to be noted is all have decimal points . I did this
if ($data[$i] =~ /^[0-9]+$/) { }
but still its not working , maybe because of decimal point . need help
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: only numeric data
by tobyink (Canon) on Jun 28, 2013 at 05:48 UTC | |
by Anonymous Monk on Jun 28, 2013 at 06:26 UTC | |
|
Re: only numeric data
by arnaud99 (Beadle) on Jun 28, 2013 at 07:18 UTC | |
|
Re: only numeric data
by Anonymous Monk on Jun 28, 2013 at 07:08 UTC |