A few new subroutines and the starts of main()