Big clean-up of part2, plus it takes user input now. Updated test to boot.