DEV Community

Discussion on: Tackling Algorithms: Counting Unique Values

Collapse
 
darkain profile image
Vincent Milum Jr

What happens when the array isn't pre-sorted?

Collapse
 
denisepen profile image
Denise Pen

If it's not pre-sorted you have to use a different approach - the multiple pointers approach won't work.