changed some of the code such that every function would be having a maximum of 25 lines of code.