Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: (Mis)Understanding <c>grep...eq $_<c>

by ikegami (Patriarch)
on Feb 24, 2009 at 06:45 UTC ( [id://745912]=note: print w/replies, xml ) Need Help??


in reply to (Mis)Understanding grep...eq $_

I thought I understood grep $person_has eq $_, $item {...} to mean:

That's not valid Perl.

search $person_has for

grep $person_has eq $_, $item searches through the list after the comma ($item), not through $person_has. The first expression tells us what is being sought: elements equal to $person_has.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (7)
As of 2024-04-25 14:30 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found