摘要: 三元运算:result = 值1 if:条件 else: 值2python3文件重视unicode用str类型来表示二进制数据用bytes来表示: encode('填写string的类型,如果没写默认utf-8') string———————————————————————————————————— 阅读全文
posted @ 2020-01-30 15:55 大魔头的取经故事 阅读(339) 评论(0) 推荐(1) 编辑
摘要: # 作者:薛志军import sysimport timename = input('请输入用户名:')with open('Name', 'r+', True, 'utf-8') as fn: names = fn.readlines() if name+'\n' not in names: # 阅读全文
posted @ 2020-01-15 01:47 大魔头的取经故事 阅读(560) 评论(0) 推荐(0) 编辑