Help for this page

Select Code to Download


  1. or download this
    my @array= (1,2,3,4);
    for my $item (@array) {
        pop @array;
        printf "Item: %s Array: %s\n",$item,join(', ', @array);
    }
    
  2. or download this
    Item: 1 Array: 1, 2, 3
    Item: 2 Array: 1, 2