human
Complete this python program:
def create_url_helper(base_url):
assistant
#Here is the Python code you requested.

    """A function to generate ``url_for`` helpers.
    """
    base_url = base_url.rstrip('/')
    def url_for(path=''):
        if path:
            path = ('/' + path.strip('/'))
        return (base_url + path)
    return url_for