Help for this page

Select Code to Download


  1. or download this
    sub main {
        foo(my $x = 1);
        say $x;
    ...
    sub foo {
        say ++$_[0] . ' in foo';
    }
    
  2. or download this
    sub main {
        bar(my $x);
        say $x;
    ...
    sub bar {
        $_[0] = 'assigned in bar';
    }