fileHandle = open ( 'G:/qqfile/1.txt','w' )fileHandle.write('abcd')#写文件 地址要用反斜杠fileHandle.close()fileHandle = open ( 'G:/qqfile/1.txt' )print (fileHandle.read() )fileHandle.close()#读文件