Re: Union of sets in O(N)
- From: tomerdr@xxxxxxxxx
- Date: 26 Jan 2007 15:01:02 -0800
Yes it is and i solved it.
On Jan 26, 3:05 pm, torb...@xxxxxxxxxxxxx (Torben Ægidius Mogensen)
wrote:
tome...@xxxxxxxxx writes:
Hi,
Suppose A,B,C.....are sets which containsrealnumbersbetween0 and 1,
(U=Union)
I need to create a set S= AUBUCU...... in O(N)
It is also known that for every x,y belong to S
MIN(ABS(X-Y))>1/m (x!=y)
Where 1/m=O(N)Don't you mean m=O(N)? Otherwise, this is trivially false.
I am planning to usehashtable to solve it but I wonder can I proveas "hash"function. Then show that the maximal number of elements that
from the above that ahashfunction withouthashcollision exist?This sounds like homework to me. I'll give you a hint: Use floor(X*N)
have the samehashfunctionis O(1).
Torben
.
- References:
- Union of sets in O(N)
- From: tomerdr
- Re: Union of sets in O(N)
- From: Torben Ægidius Mogensen
- Union of sets in O(N)
- Prev by Date: Re: Hofman and Diaby talk about P=NP at INFORMS 2007
- Next by Date: Re: need help developin better sense for context free languages
- Previous by thread: Re: Union of sets in O(N)
- Next by thread: Hardness results for queries with preprocessing
- Index(es):