无言非沉默
无言非沉默
全部文章
分类
归档
标签
去牛客网
登录
/
注册
无言非沉默的博客
全部文章
(共105篇)
题解 | #提前结束的循环#
import sys a=[3, 45, 9, 8, 12, 89, 103, 42, 54, 79] b=int(input()) for i in a: if i == b: break else: print(i)
2023-11-12
0
176
题解 | #找到HR#
import sys users_list=['Niuniu','Niumei','HR','Niu Ke Le','GURR','LOLO'] for i in users_list: if i == 'HR': print('Hi, HR! Would you like...
2023-11-12
0
183
题解 | #格式化清单#
import sys a=['apple', 'ice cream', 'watermelon', 'chips', 'hotdogs', 'hotpot'] for b in range(5,0,-1): if b == 0: print(a) else: ...
2023-11-12
0
196
题解 | #列表解析#
import sys my_list=[] for i in range(0,10): my_list.append(i) print(my_list)
2023-11-11
0
171
题解 | #2的次方数#
import sys my_list=[] for i in range(0,10): my_list.append(pow(2,i+1)) for i in my_list: print(i)
2023-11-11
0
180
题解 | #被5整除的数字#
import sys my_list=[] for i in range(0,50): my_list.append(i+1) for i in my_list: if i % 5 == 0: print(i)
2023-11-11
0
178
题解 | #前10个偶数#
import sys my_list=[0] for i in range(0,20,2): print(i)
2023-11-11
0
162
题解 | #累加数与平均值#
import sys a=input().split(" ") sum=0 for i in a: sum=sum+int(i) print("%d %.1f" %(sum,sum/len(a)))
2023-11-11
0
210
题解 | #列表的最大与最小#
import sys a=[10] for i in range(1,41): a.append(a[i-1]+1) print(a) print("{} {}".format(a[0],a[40]))
2023-11-11
0
155
题解 | #验证登录名与密码#
import sys a={ 'admis':'Nowcoder666' } b=input() c=input() if b in a.keys(): if c == a.get(b): print("Welcome!") else:...
2023-11-10
0
182
首页
上一页
1
2
3
4
5
6
7
8
9
10
下一页
末页