To write a python program to circulate the n variables using function concept
PC Anaconda - Python 3.7
Get the values from the user
Assign the value of variable to a temporary variable
Get the value from the user for the number of rotation
Using the slicing concept rotate the list
Print both the values it would be interchanged
End the program
NAME : V RAKSHA DHARANIKA
REF NO:212223230167
DEP :AI&DS
def circulate():
l=eval(input())
n=int(input())
l=l[n: ]+l[ :n]
print("After circulating the values are:",l)
The output for circulate the values of n variables is successfull.