code: def write(self, location, text, encoding):
          
          location = os.path.expanduser(location)
  
          with codecs.open(location, 'w', encoding) as f:
              f.write(text)
docs: Write file to disk.