楼兰2021
楼兰2021
全部文章
分类
题解(31)
归档
标签
去牛客网
登录
/
注册
楼兰2021的博客
全部文章
(共32篇)
题解 | #图片整理#
str_1 = input() str_2 = sorted(str_1,key=lambda x: ord(x),reverse=False) print(''.join(str_2))
2023-04-02
0
116
题解 | #删除字符串中出现次数最少的字符#
# 处理输入 str_1 = input() # 找出最小 min_1 = str_1.count(str_1[0]) lsit_1 = [] for i in str_1: lsit_1.append(i) if str_1.count(i) < min_1: ...
2023-04-02
0
133
题解 | #合法IP#
import sys import os ip_string = sys.stdin.readline().strip().split(".") result = "YES" if len(ip_string) !=&n...
Python3
2022-06-26
0
102
题解 | #合法IP#
import sys import os ip_string = sys.stdin.readline().strip().split(".") result = "YES" if len(ip_string) !=&n...
Python3
2022-06-26
0
121
题解 | #合法IP#
import sys import os ip_string = sys.stdin.readline().strip().split(".") result = "YES" if len(ip_string) != 4: result = "NO" try: for i in ip_string:...
Python3
2022-06-26
0
151
题解 | #查找兄弟单词#
import sys import os 原单词列表 list_1 = sys.stdin.readline().strip().split() list_2 = list_1[1:len(list_1)-2] string_1 = list_1[-2] print(list_2) print(s...
Python3
2022-06-26
0
191
题解 | #求int型正整数在内存中存储时1的个数#
import sys import re kk = re.compile(r"1") a = int(sys.stdin.readline().strip()) print(len(kk.findall(str(bin(a)))))
Python3
2022-04-17
0
155
题解 | #句子逆序#
import sys while True: list_1 = sys.stdin.readline().strip().split() if not&n...
Python3
2022-04-17
0
157
题解 | #统计字符#
import sys # 定义常量 s1 = "ABCDEFGHIJKLMNOPQRSTUVWXYZ" s2 = " " s3 = "1234567890" t1 ...
Python3
2022-04-16
0
174
题解 | #输入n个整数,输出其中最小的k个#
import sys a = sys.stdin.readline().strip() b = int(a.split()[0]) c = int(a.split()[1]) d = sys.stdin.r...
Python3
2022-04-07
0
202
首页
上一页
1
2
3
4
下一页
末页