• + 0 comments

    Python

    The question parameter itself wrong, pass width and cases not n

    def serviceLane(width, cases):
        # Write your code here
        all_width = []
        for each_case in cases:
            min_width = min(width[each_case[0]:each_case[1]+1])
            all_width.append(min_width)
        return all_width