code: def make_url(invocation, args=[], kwargs={}):
      
      if not invocation.endswith('/'):
          invocation += '/'
      if not invocation.startswith('/'):
          invocation = '/' + invocation
  
      url = invocation
  
      for arg in args:
          url += str(arg) + "/"
  
      if kwargs:
          url = url[:-1]
          url += "?" + urlencode(kwargs)
      
      return url
docs: >>> make_url('some/path/program', ['arg1', 'arg2'], {'arg3': 4})
      '/some/path/program/arg1/arg2?arg3=4'