code: def write_directory (zfile, directory):
      
      for dirpath, dirnames, filenames in os.walk(directory):
          zfile.write(dirpath)
          for filename in filenames:
              zfile.write(os.path.join(dirpath, filename))
docs: Write recursively all directories and filenames to zipfile instance.