Len has asked for the wisdom of the Perl Monks concerning the following question: ⭐ (strings)
prints as expected the characters (a..y) but if I change lt in le in the while expression:$char = 'a'; while ($char lt 'z') { print $char; $char++; }
it prints (a..yz) instead of the expected (a..z)while ( $char le 'z' )
Originally posted as a Categorized Question.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: lt versus le in string comparision⭐
by Abigail-II (Bishop) on Jun 13, 2002 at 14:06 UTC |