Exchange the values of variables. To swap values

How would an example look like to solve this pseudocode?

1
2
3
IF(tmpName2 <  tmpName1) 
  Change place on tmpName1 and tmpName2
  Change place on name1 and name2
Last edited on
Your terminology is odd. Perhaps you would like to exchange the values of variables. To swap values.

See http://www.cplusplus.com/reference/algorithm/swap/
Topic archived. No new replies allowed.