1 2 3 4 5
foreach(@invoices_sets) { my @retvals = process_values($_); $file_content .= $retvals[0]; $invoice += $retvals[1]; }
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30
{ package Voodoo; sub FETCH { my $self = shift; return $self->{'a'}; } sub STORE { my $self = shift; my $val = shift; $self->{'a'} += $val; } sub TIESCALAR { my $self = {}; my $class = shift; bless $self, $class; return $self; } } my $a; tie $a, 'Voodoo'; $a = 4; $a = 2; $a = 9; say $a;
($a, <wasauchimmer>) = func($_);
process_values($_, \$file_content, \$invoice);