(path, filename, output)
Generic Function to Create and write a file
Generic Function to Create and write a file
Generic Function to Create and write a file
def createFile(path, filename, output):
    ''' Generic Function to Create and write a file '''
    if not os.path.isdir(path):
        os.makedirs(path)

    fh = codecs.open(filename, encoding="utf-8", mode="w")
    fh.write(output)
    fh.close()
def createFile ( path , filename , output ) : if not os . path . isdir ( path ) : os . makedirs ( path ) fh = codecs . open ( filename , encoding = "utf-8" , mode = "w" ) fh . write ( output ) fh . close ( )