Added error checking to program end statements.