Re: efficient compare

From: Andersen <andersen_800_at_hotmail.com>
Date: Sat, 22 Apr 2006 13:21:29 +0200
Message-ID: <444A11B9.1020500_at_hotmail.com>


Alfredo Novoa wrote:

>
> If the two sets are sorted or indexed a O(n) algorithm is trivial. If
> they are not, you might use hashing or to sort them first.

Sorry I am not following. O(n) what? In number of msgs or size of total data transferred? Either case, it does not sound efficient, here is the algorithm for the latter, assuming n is the number of items in the set A union B
send A to B, A execute A=A union B
send A to B, B execute B=A union B

Or were you talking bit complexity?

I want to do some kind of hashing... Received on Sat Apr 22 2006 - 13:21:29 CEST

Original text of this message