摘要: name='liming'age = 20#1 字符串拼接,变量age必须是str类型print('he is '+str(age)+' years old')执行结果he is 20 years old#2 %s代表变量,print('he is %s years old' % age)执行结果he is 20 years old #3 formatprint('{} is {} years... 阅读全文
posted @ 2019-08-21 16:42 Wsnan 阅读(3260) 评论(0) 推荐(0)
摘要: 原文链接:https://www.cnblogs.com/ming5218/p/7965973.html 一、ConfigParser简介 ConfigParser 是用来读取配置文件的包。配置文件的格式如下:中括号“[ ]”内包含的为section。section 下面为类似于key-value 阅读全文
posted @ 2019-08-21 11:20 Wsnan 阅读(458) 评论(0) 推荐(0)