adding some comments to the code