torres09 has asked for the wisdom of the Perl Monks concerning the following question:
hey
I have written an if code , which should be true only when it has a non numeric data in array cell
if ($array_H[$i] !~ /^[0-9]+$/) { block; }
but somehow if loop block is visited even if data is numeric
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: non numeric data
by derby (Abbot) on Jun 24, 2013 at 12:53 UTC | |
by torres09 (Acolyte) on Jun 24, 2013 at 13:00 UTC | |
by hdb (Monsignor) on Jun 24, 2013 at 13:06 UTC | |
by hdb (Monsignor) on Jun 24, 2013 at 13:15 UTC | |
by BillKSmith (Monsignor) on Jun 24, 2013 at 14:59 UTC | |
|
Re: non numeric data
by ramlight (Friar) on Jun 24, 2013 at 13:13 UTC | |
|
Re: non numeric data
by blue_cowdawg (Monsignor) on Jun 24, 2013 at 12:53 UTC | |
|
Re: non numeric data
by Happy-the-monk (Canon) on Jun 24, 2013 at 13:37 UTC | |
by tobyink (Canon) on Jun 24, 2013 at 14:10 UTC | |
by Happy-the-monk (Canon) on Jun 24, 2013 at 16:06 UTC | |
|
Re: non numeric data
by hdb (Monsignor) on Jun 24, 2013 at 12:46 UTC |