〓Fly〓
〓Fly〓
全部文章
题解
归档
标签
去牛客网
登录
/
注册
〓Fly〓的博客
全部文章
/ 题解
(共26篇)
题解 | #汽水瓶#
def f(n): a=n//3 b=a+n%3 if b==2: &nbs...
Python3
2022-04-04
0
194
题解 | #简单密码#
l=[] d={'abc':2,'def':3,'ghi':4,'jkl':5,'mno':6,'pqrs':7,'tuv':8,'wxyz':9} for n in s: if n.islower(): for key in d: if n in k...
Python3
2022-04-04
0
163
题解 | #字符串反转#
s = str(input()) # 断言:不能加括号 assert len(s)<=1000,'字符串长度不得超过1000' assert s.islower(),'字符串需小写' print(s[::-1])
Python3
2022-04-03
0
172
题解 | #计算某字符出现次数#
s=input() for i in s: if len(s)<=8: print(s+'0'*(8-len(s))) break else: print(s[:8]) s=s[8:]
Python3
2022-04-03
0
150
题解 | #输入整型数组和排序标识,对其元素按照升序或降序进行排序#
a=int(input()) b=list(map(int,input().split())) c=int(input()) if c == 0: for i in sorted(b)[:a]: print(i,end=' ') elif c == 1: for j ...
Python3
2022-04-02
0
161
题解 | #输入n个整数,输出其中最小的k个#
while True: try: n,k=map(int,input().split()) l=list(map(int,input().split())) print(' '.join(map(str,sorted(l)[:k]))) ...
Python3
2022-04-02
0
160
首页
上一页
1
2
3
下一页
末页