adding comments to helper functions