Adding printf debugging to main for problem 144.