So I am implementing a block swap algorithm in python.
The algorithm I am following is this:
Initialize A = arr[0..d-1] and B = arr[d..n-1] 1) Do following u
def leftRotation(): li = [int(x) for x in input().split()] d = int(input()) ans = (li[d:]+li[0:d]) for i in ans: print(i,end=' ') print() leftRotation()