print(r"""'To be, or not to be:
that is the question.
Whether it's nobler in the mind to suffer.'""")
that is the question.
Whether it's nobler in the mind to suffer.'""")
2022-11-01
print(r"""'\"To be, or not to be\": that is the question.\n Whether it\'s nobler in the mind to suffer.'""")
2022-11-01
已采纳回答 / qq_终结的开始_0
函数里面取值用中括号[ ] 不是用小括号( )names = kwargs['names'] gender = kwargs['gender'] age = kwargs['age']
2022-10-29
age = 1
if age>=18:
print('adult')
elif age>=6:
print('teenager')
elif age>=3:
print('kid')
else:
print('baby')
嘿嘿,可以这么写
if age>=18:
print('adult')
elif age>=6:
print('teenager')
elif age>=3:
print('kid')
else:
print('baby')
嘿嘿,可以这么写
2022-10-28
已采纳回答 / weixin_慕侠6136764
sum 本身在python中充当求和函数,当在使用时会被编辑器标注(指颜色),当使用已有定义的名称充当变量名时,基本都是有颜色标注
2022-10-26
最赞回答 / 张张包529
因为L是二维list,对于二维list,列表里面的每一个元素仍然是一个列表,所以L[0]代表的是第一个数组而cube是一维list,它里面只包含了三个元素,所以cube[0]代表这个一维数组里的第一个元素
2022-10-25