Replacing "print >> file,content" function to "file.write(content)" because python 3 does not support the previous function.