3 ms·
That's what I though as well. In which case it's better to just keep it in a set-like structure initially, or just dump your entire array into a set afterwards.
by Adamantcheese 8y ago
That's what I though as well. In which case it's better to just keep it in a set-like structure initially, or just dump your entire array into a set afterwards. That's linear time, which is loads better than any of the solutions presented.