Help for this page

Select Code to Download


  1. or download this
    # works as expected!
    
  2. or download this
    my @myCities = (1 .. 2);
    my $city = "before";  # now is scoped to the whole package!
    ...
    
    # ... unless you expected it to print "after"
    # ... actually it prints "before"