Homework 5 continued progress.

Working through sort loop.
Untested and not debugged.