def firstBadVersion(self, n):
:type n: int
self.__getitem__ = isBadVersion
return bisect.bisect_left(self, True, 1, n)
What a shame that people are downvoting this. I upvoted.
Thx, this code is just for fun XD
Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.