CPSC 203: Introduction to computers  

James Tam

Final exam review: Computer programming (Question 3 solution)

def swap (num1, num2):

     temp = num1

     num1 = num2

     num2 = temp

     return num1, num2