Wrote the base code for the program.