We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
hello
thanks for sharing, it is pretty efficient.
Why are you using ind=bisect.bisect_left(a1,pr+1) ? I know that the goal is to maximize pr-a1[ind]+m but is it not possible that the maximisation is pr + 2 in few special case ?
Cookie support is required to access HackerRank
Seems like cookies are disabled on this browser, please enable them to open this website
Maximum Subarray Sum
You are viewing a single comment's thread. Return to all comments →
hello thanks for sharing, it is pretty efficient. Why are you using ind=bisect.bisect_left(a1,pr+1) ? I know that the goal is to maximize pr-a1[ind]+m but is it not possible that the maximisation is pr + 2 in few special case ?