Perl Warts

misfeatures and other problems
PERL| PHP| PYTHON| RUBY
What do each of the following programs do? (all answers)
(answer)
#!/usr/bin/perl

foreach $x (1,2,3,4,5) {
  print "x: $x\n";
  if ($x > 2) { print "break\n"; break; }
}
answer
PERL| PHP| PYTHON| RUBY
Last modified: March 30, 2006 @ 6:47 MST
Copyright (C) 1996-2017 Selene Scriven