Code Formatting and Commenting Done

Proper Code formatting and Commenting done, removed unnecessary and
commented code