Added comments and made some of the code look clear
Most of the commenting is done