Ok, Mr. Balaz.
2009/2/23 Miroslav Balaz :
> Yes but you mus be careful with c+r.
> p
> you should use c*X+r, where X is large enough number.
> If you X is 2 to 16,(16th power of two), the you get the same as using first
> two bytes for collection and second for number,
> but you can use.
==> Yes,
Yes but you mus be careful with c+r.
p
you should use c*X+r, where X is large enough number.
If you X is 2 to 16,(16th power of two), the you get the same as using first
two bytes for collection and second for number,
but you can use.
The radix sort is good idea.
But i suppose not to keep data se
Hello again Mr. Balaz,
I`m writting to thank You very, very so much about yours information,
that give "the path of stones" to solution my problem.
I think very well in this weekend and I came to this conclusion:
All collections have a number maximum limit MAX (C), where MAX (C) ≤
2000 for each
I thing you the only choice, is binary search tree, but it is the most
obvious one. It imposible to make it independent form cards universe,as far
as i know
but it can be made int time O(log(nmU)),where U is number of cards, it is
much less than O(n).
But you must think about what is the problem, i
Very thanks Mr. Balaz.
The really situation is : I must to make a program that manage this
"exchange cards problem" and I did not have any idea how to attack
this problem. I need to know how put the card's numbers into a
structure that a search to a desired/recurring item at least run in
time no
This is not algorithm problem, it is homework problem do it yourself.
I see there one problem, and it is how large is N
I suggest you to represent sets as pairs(cardID,repeat number )
that means for each card you remember number of how much you have of that
card, and when there is zero, it means