Do I need bottom <= top in my while loop for binary search?

前端 未结 0 1205
逝去的感伤
逝去的感伤 2020-11-22 05:51
public static int binSearch (double[] list, double item)
{
   int bottom = 0;                 // lower bound of subarray
   int top = list.length - 1;         // upp         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题