Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: A "simple" question regarding accessing a value in a complex data structure.

by wjw (Curate)
on Oct 09, 2013 at 07:08 UTC ( #1057493=note: print w/replies, xml ) Need Help??


in reply to A "simple" question regarding accessing a value in a complex data structure.

Try this,
use strict; use warnings; my %tgs = ( 'articles' => { 'Java' => 'How to Program in Java', 'Perl' => 'Perl Programming for Biologists', 'Python' => { 'Programming' => q/Expert's Guide to Scala/ +, }, }, 'eBooks' => { 'Linux' => q/Linux: A Beginner's Guide/, }, ); print $tgs{articles}{Python}{Programming};
Hope that helps,
...the majority is always wrong, and always the last to know about it...
Insanity: Doing the same thing over and over again and expecting different results.
  • Comment on Re: A "simple" question regarding accessing a value in a complex data structure.
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1057493]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (12)
As of 2016-12-09 21:27 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (157 votes). Check out past polls.