C:\>cat ttt.pl
use strict;
use warnings;
{
my $x = 'A';
sub f { sub { $x++ } }
sub g { sub { $x++ } if $x }
}my $F=f(); my $G=g(); print $F->(),$G->(),"," for 1..4; print "\n"; C:\>ttt.pl 0A,1B,2C,3D, C:\>
C:\>cat ttt.pl
use strict;
use warnings;
{
my $x = 'A';
sub f { sub { $x++ } }
sub g { sub { $x++ } if $x }
}my $F=f(); my $G=g(); print $F->(),$G->(),"," for 1..4; print "\n"; C:\>ttt.pl 0A,1B,2C,3D, C:\>