孤寡孤寡的牛肉丸很甜美
孤寡孤寡的牛肉丸很甜美
全部文章
分类
归档
标签
去牛客网
登录
/
注册
孤寡孤寡的牛肉丸很甜美的博客
全部文章
(共4篇)
题解 | 数对计数
#题解没用前几个题讲的bisect函数,我写了一个用bisect函数的,我也写了count那个办法,但不知道为什么超时了 import bisect n, c = map(int, input().split()) A = list(map(int, input().split())) A.sort...
2025-08-14
1
27
题解 | 参议院投票
class Solution: def predictVictory(self , s: str) -> str: n = len(s) stackR = [] stackD = [] for i in range(n):...
2025-08-13
1
22
题解 | 素数判断
import math T = int(input()) for i in range(T): n = int(input()) print((lambda n: 'No' if any ( n%c == 0 for c in range(2, int(math.sqrt(n))+1...
2025-08-03
2
35
题解 | 卡拉兹函数
print( (lambda n:{1: 3*n+1, 0: n//2}[n%2]) (*map(int, input().split())) )
2025-08-02
1
18