a = 2 b = 3 # Swap using a temp variable temp = b b = a a = temp # While evaluating an assignment, the right-hand side # is evaluated before the left-hand side a, b = b, a