3D images taken using indirect reflected light [#3D]
-
This 3D Picture Was Created Without a Camera "A projector shines hundreds
of random computer-generated, black-and-white patterns on an object, while
four s...
34 minutes ago
Need to look through entire array (of a length N) to be sure, and one approach could be to use 2 hash tables while doing that, one for occurence (or count) of all element numbers and one for occurence of single elements - this can be done in O(N)
ReplyDeletecode:
https://gist.github.com/878167
The vector contains n+1 unique and 2*n reps, so I can stop when the size of first hash reaches n+1 items.
ReplyDelete