Wednesday, April 18, 2018

Why is My Binary Search Taking So Long?

Are you sending a new list with each recursive call?

Better to have just that one original list and keep passing the reference.

If you have to compute the length of the list just to do the basic comparisons, that will hit you..

No comments: