swap test in python code example Example: swapping in python x = 5 y = 10 x, y = y, x print("x =", x) print("y =", y)