摘要: 1print 变量 abc = False joke_string = "Isn't that joke so funny?! %r" print joke_string %abc 结果: Isn't that joke so funny?! False 若改成下面这样: print joke_st 阅读全文
posted @ 2016-10-11 18:41 guohuino2 阅读(307) 评论(0) 推荐(0) 编辑
摘要: 1 =(单等号)和==(双等号)的区别 =用来赋值, ==用来判断是否相等 2 x = 100 在操作符2侧加空格,易读 3 打印时,进行字符串拼接 print "there are", cars, "cars available." 2对双引号中,末尾或者开头,不需要加空格, cars可以自动带空 阅读全文
posted @ 2016-10-11 18:20 guohuino2 阅读(153) 评论(0) 推荐(0) 编辑
摘要: 1 数学运算符号 + plus 加号 - minus 减号 / slash 除法 * asterisk 乘法 % percent 模除 求余 < less than 小于号 > greater than 大于号 <= less than equal 小于等于号 >= greater than equ 阅读全文
posted @ 2016-10-11 15:38 guohuino2 阅读(148) 评论(0) 推荐(0) 编辑