Update the program. Improved it slightly

Moved some of the variables around to make it nicer.