code: def menu(self, prompt, choices):
          
          menu = [prompt] + [
              "{0}. {1}".format(*choice) for choice in enumerate(choices, start=1)
          ]
          command = 'inputlist({})'.format(repr(menu))
          choice = int(self._vim.eval(command))
  
          # Vim returns weird stuff if user clicks outside choices with mouse
          if not 0 < choice < len(menu):
              return
  
          return choices[choice - 1]
docs: Presents a selection menu and returns the user's choice.
  
          Args:
              prompt (str): Text to ask the user what to select.
              choices (Sequence[str]): Values for the user to select from.
  
          Returns:
              The value selected by the user, or ``None``.
  
          Todo:
              Nice opportunity to provide a hook for Unite.vim, etc. here.