• + 0 comments

    Python code:

    def rotateLeft(d, arr): lst = [] for j in range(n): lst.append(arr[(j+d)%n]) return lst