A = [1,2,3,4,5,6] A[2:4] = A[2:4][::-1] print(A)