Seriously, the while loop is also different (doesn't matter here but does in more real code where a s//g is the condition of a while with a non-empty body) because without the /g modifier the pos will not be set and /G doesn't work.
—John
In reply to Pumping Lemma
by John M. Dlugosz
in thread 1 while s/// vs s///g
by merlyn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |