3 ms·
True, in which case you can take some measures to avoid worst case inputs... I'm thinking randomization in quicksort, for instance.
by emmanueloga_ 12y ago
True, in which case you can take some measures to avoid worst case inputs... I'm thinking randomization in quicksort, for instance.
- harperlee 12y agoI always liked a lot that solution ("adding noise"), it seems very elegant.