seaver has asked for the wisdom of the Perl Monks concerning the following question:
I have filled a PDB object with atoms:
I want to access all the numbers like so:$self->{'atoms'}{$number}=$atom;
but in the line above, @numbers turns up empty...!?! I can reference any atom directly:my @numbers = keys %{$self->{'atoms'}};
But just cannot get a list of the numbers, Im sure ive misunderstood something about this, but i dont know what?print $self->{'atoms'}{'2000'}."\n";
cheers
Sam
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Getting keys from a referenced hash
by rkg (Hermit) on Sep 23, 2003 at 19:13 UTC | |
|
Re: Getting keys from a referenced hash
by seaver (Pilgrim) on Sep 23, 2003 at 17:20 UTC | |
by dragonchild (Archbishop) on Sep 23, 2003 at 17:31 UTC |