Ice Cream Parlor

  • + 0 comments

    Python

    def icecreamParlor(m, arr):
        for i in range(len(arr)-1):
            j = i + 1
            while j < len(arr):
                if arr[i] + arr[j] == m:
                    return i+1, j+1
                j += 1