Detailed comment added inside the function code