A
Andrew
Hi,
Please help me in solving next problem(I search in FAQ bun have not
find an answer):
There is a sub foo which return hash:
sub foo{my %in=( key1=>value1
key2=>value2
key3=>value3);
}
I need to assess elements of returned hash without assigning to a
variable. Something like this:
print @&foo(){'key1','key2'};
print $&foo(){'key1'};
But this does not work: "Bareword found where operator expected"
Thanks,
Andrew
Please help me in solving next problem(I search in FAQ bun have not
find an answer):
There is a sub foo which return hash:
sub foo{my %in=( key1=>value1
key2=>value2
key3=>value3);
}
I need to assess elements of returned hash without assigning to a
variable. Something like this:
print @&foo(){'key1','key2'};
print $&foo(){'key1'};
But this does not work: "Bareword found where operator expected"
Thanks,
Andrew