%hash = map { $_ => 1 } @pclist;  is correct

Krishnakumar K.P
Sr.Software Engineer
Cybage Software Pvt. Ltd (An SEI-CMMI Level 5 Company)
West Avenue, Kalyani Nagar
Pune - 411 006
Tel: 020- 66041700/  66044700 extn: 3178
Email: [EMAIL PROTECTED] 
Website: www.cybage.com



-----Original Message-----
From: Jeff Peng [mailto:[EMAIL PROTECTED]
Sent: Wednesday, July 19, 2006 1:13 PM
To: [EMAIL PROTECTED]; beginners@perl.org
Subject: RE: check existence of element in a list



>my %hash = map { $_ => 1 } @pclist;

above is wrong.It should be:
my %hash = map { $_, 1 } @pclist;

HTH.



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to