in reply to Re^2: I'm getting some weird error
in thread I'm getting some weird error

Perl offers two ways to dereference (most) datatypes. Same for hashes and arrays.

You mixed both (and Corion explained what happend)

See perlreftut and References quick reference for more.

Cheers Rolf
(addicted to the Perl Programming Language :)
Wikisyntax for the Monastery FootballPerl is like chess, only without the dice