4 ms·
> Your code iterated more than once. Uh... no. *edit The first element is iterated three times, the second two times and the rest once, making it O(n).
by thomasz 14y ago
> Your code iterated more than once.
Uh... no.
*edit The first element is iterated three times, the second two times and the rest once, making it O(n).