Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: how to find common and not common lines in 2 files?

by misc (Pilgrim)
on Aug 21, 2007 at 21:45 UTC ( #634199=note: print w/replies, xml ) Need Help??


in reply to how to find common and not common lines in 2 files?

Since you did say you started with perl a few weeks ago,
I'd like to give you just a hint.
Why don't you read the second file line by line and ...

Besides, as this was your question, you could find common and uncommon keys of two hashes by using a foreach loop, iterating over the keys of hash a and testing if it's present in hash b.

The hash category in perlfunc should also help you.
Did you miss exists ?

michael
  • Comment on Re: how to find common and not common lines in 2 files?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://634199]
help
Chatterbox?
Discipulus played the guitar in a ska band 12 elemnts, very fun
[LanX]: well ... the prize for worshipping satan is high ...
[Discipulus]: you value too much your soul LanX
[Eily]: LanX: you mean people end up losing their health insurance?
LanX could be a reference to Trump and/or Brexit ...
[LanX]: ... anyway getting a support call from food! Need to respond ... ;-)
LanX see you later

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (14)
As of 2017-03-24 12:40 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (301 votes). Check out past polls.