in reply to Large Set Efficiency Question

In the example you give, your arrays are sorted. If this is always the case (or can be made to be), then you could iterate the two arrays in sloppy-lockstep--Dave

Replies are listed 'Best First'.
Re: Re: Large Set Efficiency Question
by jackdied (Monk) on Jul 30, 2002 at 00:12 UTC
    If I am reading the question correctly, I would use a modified version of dpuu's parent post.

    sort -u -t '|' infile1 infile2 | perl myprog.pl

    And just have myprog.pl look for lines where the leading key is repeated two lines in a row. If the timestamp was the same in both files, there will be only one row (-u means make unique).

    -jack