Help for this page

Select Code to Download


  1. or download this
    print "Scalar assignment:\n";
    $x = ( context(1), context(2), context(3) );
    ...
    2: list context
    3: list context
    @x = oranges lemons oranges lemons oranges lemons
    
  2. or download this
    use warnings;
    sub list { ('a','b','c') }
    my @all= list();
    my $last= list(); # Doesn't produce a warning