python学习笔记2
摘要:
创建一个文件并往里面写入内容import os# coding='utf-8'#取得OS的换行符ls = os.linesep# 获取文件名while True: fname = raw_input('input file name: ') if os.path.exists(fname): print "ERROR : '%s' already exists!" % fname else: breakprint fname#获取文件的内容all = []print "\nEnter lines('.' 阅读全文
posted @ 2011-06-14 21:56 司徒正美 阅读(1145) 评论(1) 推荐(0)
浙公网安备 33010602011771号