loading...

re: Daily Coding Problem #1 VIEW POST

TOP OF THREAD FULL DISCUSSION
re: This page lists the complexities of the major data structures in Python. Sets and dicts have a similar implementation. The lookup is O(1) in averag...

I do not think there is an upper range of numbers and they are also not subsequent, so using an array like a hashset is not usefull in this particular situation

Yes. I was not sure of that constraint. In that case, set is better.

Code of Conduct Report abuse