CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Intermediate: Re: [200120022003] Dymanic Variable with Perl: Edit Log



7stud
Enthusiast

Mar 25, 2010, 3:16 AM


Views: 1674
Re: [200120022003] Dymanic Variable with Perl


Code
use strict; 
use warnings;
use 5.010;

my %info_for = (
tom => ['ibm', 'abc@xxx'],
betty => ['google', 'xyz@xxx'],
);

my $name = 'tom';
say "@{$info_for{$name}}";

--output:--
ibm abc@xxx



(This post was edited by 7stud on Mar 25, 2010, 3:18 AM)


Edit Log:
Post edited by 7stud (Enthusiast) on Mar 25, 2010, 3:18 AM


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives