Beefy Boxes and Bandwidth Generously Provided by pair Networks DiBona
Welcome to the Monastery
 
PerlMonks  

Re: Can't use string ("16") as a HASH ref while "strict refs" in use

by CountZero (Chancellor)
on Jun 30, 2012 at 08:12 UTC ( #979216=note: print w/ replies, xml ) Need Help??


in reply to Can't use string ("16") as a HASH ref while "strict refs" in use

The whole of

my @chr_temp=split //,$arr[0]; for(1..3) { shift(@chr_temp); } $arr[0]=join("",@chr_temp);
can be replaced by:
$arr[0] = substr($arr[0], 3);
Now as to our problem: Are you sure, there isn't a typo in
$site_info{$arr[0]{$arr[1]}}{"value"}=$arr[3];
and you really meant
$site_info{$arr[0]}{$arr[1]}{"value"}=$arr[3];

CountZero

A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

My blog: Imperial Deltronics


Comment on Re: Can't use string ("16") as a HASH ref while "strict refs" in use
Select or Download Code
Re^2: Can't use string ("16") as a HASH ref while "strict refs" in use
by thudzj (Initiate) on Aug 23, 2012 at 02:55 UTC

    Thanks a lot! I checked it several times to find it out! This is a stupid mistake!

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://979216]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (4)
As of 2013-05-24 05:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best material for plates (tableware) is:









    Results (496 votes), past polls