updated comments on functions