Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Difference Between Two array

by nashkab (Novice)
on Jan 04, 2008 at 18:57 UTC ( #660450=perlquestion: print w/ replies, xml ) Need Help??
nashkab has asked for the wisdom of the Perl Monks concerning the following question:

I Have Two Arrays:
1st Array Content SDT `1781183799.44927\' ----- BN `1781183799.44972\' ----- BNN `1781183799.46753\' -----
2nd Array Content SDT `1781183799.44927\' ----- BN `1781183799.44972\' -----

I want the difference between the two arrays.

Resulting array will look like BNN `1781183799.46753\' -----

Code Please!!!

Comment on Difference Between Two array
Select or Download Code
Re: Difference Between Two array
by phenom (Chaplain) on Jan 04, 2008 at 19:06 UTC
    The module List::Compare looks like a good fit. Give that a shot and post back if you need help. HTH
Re: Difference Between Two array
by amarquis (Curate) on Jan 04, 2008 at 19:06 UTC
    perldoc perlfaq4

    Under "How do I compute the difference of two arrays? How do I compute the intersection of two arrays?"

    In general, the Perl documentation or a quick search here will show you how to do almost any basic, common task.

Re: Difference Between Two array
by marto (Bishop) on Jan 04, 2008 at 19:12 UTC
      hmmm is school back in session?? these posts looks like homework. where's paco?
Re: Difference Between Two array
by CountZero (Bishop) on Jan 04, 2008 at 22:02 UTC
    Code Please!!!
    Yes indeed, where is your code to show us that you at least tried?

    CountZero

    A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

      judging from his few other writeups, it always sounds like "I need to have that done. Do it for me! ...oh no! I need it done like this, not like that".

      Nashkab, I don't just want to blame you. I'd like to recommend you to really try hard yourself because this is what will bring you further. You remember better what you created than what other people created. You can also learn a lot from your mistakes. You don't see those if you just prompt other people around for spitting out the correct code for you.

      ...looking forward to providing some Perl help when you'll _really_ get stuck after _really_ trying.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://660450]
Approved by Corion
Front-paged by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (5)
As of 2014-12-26 02:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (164 votes), past polls