Write a function swap that swaps the first and last elements of a list argument. Sample output with input: 'all, good, things, must, end, here' ['here', 'good', 'things', 'must', 'end', 'all']
Answers (2)
Given two int variables, i and j, which have been declared and initialized, and two other int variables, itemp and jtemp, which have been declared, write some code that swaps the values in i and j by copying their values to itemp and jtemp
Answers (1)