fuxiaohua
fuxiaohua
全部文章
分类
题解(9)
归档
标签
去牛客网
登录
/
注册
fuxiaohua的博客
全部文章
(共9篇)
题解 | #矩阵乘法#
def func(): while True: try: x, y, z = int(input()), int(input()), int(input()) m1, m2 = [], [] m3 = [...
2021-08-08
1
361
题解 | #名字的漂亮度#
def calc(name): ss = set(name) # 去重 sd = {} res = 0 for i in ss: sd[i] = name.count(i) # 算字符出现次数 x = sorted(sd.value...
2021-08-08
0
450
题解 | #迷宫问题#
def find_mg(start_x, start_y, end_x, end_y, mg_list, step_list): step_list_tmp = step_list if start_x == end_x and start_y == end_y: # 结束条件 ...
2021-08-08
0
325
题解 | #查找组成一个偶数最接近的两个素数#
def isprime(x): if x == 1: return False for i in range(2, x): if x%i == 0: return False return True def func(...
2021-08-08
0
345
题解 | #DNA序列#
def func(): while True: try: s, n = str(input().strip()), int(input()) max_r = 0 max_s = '' ...
2021-08-08
1
236
题解 | #MP3光标位置#
def func(): while True: try: nums, ops = int(input()), str(input().strip()) cur = 1 start = 1 ...
2021-08-08
0
308
题解 | #字符串加密#
def func(): while True: try: enc, s = str(input()), str(input()) old = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' ne...
2021-08-07
0
303
题解 | #图片整理#
def func(): while True: try: s = str(input()) print(''.join(sorted(s))) except: break if __n...
2021-08-07
0
266
题解 | #字符串通配符#
import re def func(): while True: try: p, s = str(input()), str(input()) a = "[a-zA-Z0-9\.]{0,}" ...
2021-08-07
0
366