Page 673 - AP Computer Science A, 7th edition
P. 673

18. (E) The algorithm has three steps:
1. Store the object at i in temp.
2. Place at location i the object at j. 3. Place temp at location j.
This has the effect of swapping the objects at i and j. Notice that choices B and C, while incomplete, are not incorrect. The question, however, asks for the best description of the postcondition, which is found in choice E.































































































   671   672   673   674   675