reverse order list code example
Example 1: how to reverse a list in python
my_list = [1, 2, 3, 4, 5]
my_list.reverse()
Example 2: reverse function python
# The Reverse operation - Python 3:
Some_List = [1, 2, 3, 4, 1, 2, 6]
Some_List.reverse()
print(Some_List)
# Result: [6, 2, 1, 4, 3, 2, 1]