Help for this page

Select Code to Download


  1. or download this
    my @array = (1 .. 10);
    my $counter;
    foreach my $element (@array) {
        print "Last element follows now!\n"    if ++$counter == scalar(@ar
    +ray);
        print "$element\n";
    }
    
  2. or download this
    1
    2
    3
    ...
    9
    Last element follows now!
    10