-
#通过列表索引打印出第一二三名
L = [95.5, 85, 59, 66, 72]
print(L(0),L(1),L(5))查看全部 -
s1='ABC'
s2='123'
s3='xyz'
#请输出s1、s2、s3中所有字符的排列。
for m in s1:
for n in s2:
for b in s3:
print(m+n+b)查看全部 -
i=1
s=1
while i ≤10:
s=s*i
i=i+1
print(s)查看全部 -
L = [75, 92, 59, 68, 99]
for i in L :
i +=i
n=len(L)
m=i/n
print m查看全部 -
age=5
if age>=18:
print("adalt")
elif age<3:
print("baby")
elif age<15:
print("kids")
else:
print("teenager")查看全部 -
age=16
if age>=18:
print("adalt")
elif age<3:
print("baby")
elif age<15:
print("teenager")
else:
print("kids")查看全部 -
age=19
if age>18:
print("adalt")
else :
print("teenager")查看全部 -
age=19
if age>18:
print("adalt")
else:
pass查看全部 -
age=19
if age>18:
print("adalt")
else :
pass查看全部 -
print("这是一句中英文混合的Python字符串:Hello World!")查看全部
-
print(r'''
'\"To be, or not to be\": that is the question.\nWhether it\'s nobler in the mind to suffer.'''')查看全部 -
print('我',"是",\一个,\n小,学\t,生)查看全部
-
a='\'我\',\"是\",\\一个,\\n小,学\\t,生'查看全部
-
a='\'我\',\"是\",\\一个,\n小,学\t,生'查看全部
-
for i in range(len(s1)):
print(f'{s1[i]}: {s2[i]}')
查看全部
举报
0/150
提交
取消