@@ -0,0 +1,1144 @@
+class Solution(object):%0A    def searchRange(self, nums, target):%0A        %22%22%22%0A        :type nums: List%5Bint%5D%0A        :type target: int%0A        :rtype: List%5Bint%5D%0A        %0A        Note variations, %0A        to go low, set high to mid on find. %0A        to go high, set low to mid + 1 on find%0A        %22%22%22%0A        %0A        %0A        index1 = -1%0A        index2 = -1%0A        if not nums:%0A            return %5Bindex1,index2%5D%0A        high = len(nums)%0A        low = 0%0A        while low %3C high:%0A            mid = low + (high - low)/2%0A            if nums%5Bmid%5D %3E target:%0A                high = mid%0A            elif nums%5Bmid%5D  %3C target:%0A                low = mid + 1%0A            else:%0A                index1 = mid%0A                high = mid %0A                %0A        low = index1 %0A        high = len(nums)%0A        while low %3C high:%0A            mid = low + (high - low)/2%0A            if nums%5Bmid%5D %3E  target:%0A                high = mid%0A            elif nums%5Bmid%5D %3C target:%0A                low = mid + 1%0A            else:%0A                index2 = mid %0A                low = mid + 1%0A         %0A        return %5Bindex1,index2%5D%0A                %0A                %0A        %0A

Create searchRange.py from Leetcode