python可以通过open函数打开文件,通过close函数关闭文件
#!/usr/bin/python # Open a file fo = open("foo.txt", "wb") print "Name of the file: ", fo.name # Close opend file fo.close()
python可以通过open函数打开文件,通过close函数关闭文件
#!/usr/bin/python # Open a file fo = open("foo.txt", "wb") print "Name of the file: ", fo.name # Close opend file fo.close()