2013-Dec-17: Homework from review, refactorings and cleanup (ongoing)