in reply to Matching numeric value between two digits
use warnings; use strict; for (qw(1 2 3 4 20.5 97 -5)) { if (($_ >= 1) and ($_ <= 75) and (!/\./)) { print "$_ yes\n"; } else { print "$_ no\n"; } } __END__ 1 yes 2 yes 3 yes 4 yes 20.5 no 97 no -5 no
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Matching numeric value between two digits
by shadowfox (Beadle) on Feb 04, 2013 at 22:44 UTC | |
by Crackers2 (Parson) on Feb 04, 2013 at 23:27 UTC |