Commenting

Added comments for better understanding of the code