Help for this page

Select Code to Download


  1. or download this
    use strict;
    use warnings;
    ...
    print $a[1][2];  # Print element 2 of the array ref'ed by $a[1].
    print $b[0][2];  # Print element 2 of the array named by $b[0].
    print $b[1][2];  # Print element 2 of the array ref'ed by $b[1].
    
  2. or download this
    Can't use string ("1") as an ARRAY ref while "strict refs" in use at s
    +cript.pl line 8.
    
  3. or download this
    unshift @a, [ ];
    $a[0][0]=4;
    $a[0][1]=5;
    $a[0][2]=6;
    
  4. or download this
    unshift @a, [ 4, 5, 6 ];