摘要:
age_of_princal = 56guess_age = int(input("e guess a age:"))if guess_age == age_of_princal: print("Bingo,you are right")else: print("No,you are wrong") 阅读全文
posted @ 2018-11-08 10:41
小水胖
阅读(394)
评论(0)
推荐(0)
摘要:
+号可以用来做字符串拼接 print("abc"+"efg"+"def") abcefgdef 字符串(str)与数字(int)不能使用+进行拼接 阅读全文
posted @ 2018-11-08 09:59
小水胖
阅读(236)
评论(0)
推荐(0)
摘要:
input:与用户的交互,返回用户输入的值 注意:input接受的所有数据都为字符串,即便输入的为数字,依然会被当成字符串 阅读全文
posted @ 2018-11-08 09:45
小水胖
阅读(407)
评论(0)
推荐(0)
摘要:
str(string): 字符串 str(被转换的数据) int(interger):整数 int(被转换的数据) 阅读全文
posted @ 2018-11-08 09:42
小水胖
阅读(117)
评论(0)
推荐(0)

浙公网安备 33010602011771号