1#!/usr/bin/perl 2 3# Copyright 2002-2019, Paul Johnson (paul@pjcj.net) 4 5# This software is free. It is licensed under the same terms as Perl itself. 6 7# The latest version of this software should be available from my homepage: 8# http://www.pjcj.net 9 10use strict; 11use warnings; 12 13my @x; 14 15sub xx { 16 $x[shift]++; 17} 18 19for (0 .. 10) { 20 time && 21 $x[1]++; 22 23 $x[2]++ 24 if time; 25 26 for (0 .. 2) { 27 $x[3]++; 28 } 29 30 if (time) { 31 xx(4); 32 } else { 33 $x[5]++; 34 } 35} 36