text: Run binary search only until the index of last negative Integer in the above row
code: nextEnd = getLastNegativeIndex ( M [ i ] , 0 , nextEnd , 4 ) NEW_LINE count += nextEnd + 1 NEW_LINE return count NEW_LINE