You are viewing a single comment's thread. Return to all comments →
My respost in Python:
def rotateLeft(d, arr): n = len(arr) d = d % n return arr[d:] + arr[:d]
I used loops the first time, but they weren't very efficient.
Seems like cookies are disabled on this browser, please enable them to open this website
Left Rotation
You are viewing a single comment's thread. Return to all comments →
My respost in Python:
I used loops the first time, but they weren't very efficient.