in reply to How to check if a string contains more than 1 character?
How about this one?
$ perl -e '$string= "f"; $a=7; print "larger than 1 \n" if length $str +ing > ($a*$a - ($a+1)*($a-1));' $ perl -e '$string= "foo"; $a=7; print "larger than 1 \n" if length $s +tring > ($a*$a - ($a+1)*($a-1));' larger than 1 $
|
---|
In Section
Seekers of Perl Wisdom