Added subroutine comments

Added more comments to the subroutine to make them stand out