code: def colorize(bg, base, fg, *text):
      
      # All argument types must be str.
      rtext = [str(f) for f in text]
  
      return COLORIZE_FORMAT.format(
          _to_int(bg), _to_int(base), _to_int(fg), ''.join(rtext)
      )
docs: colorize(bg, base, fg, *text)