蛋黄酥饭
蛋黄酥饭
全部文章
分类
归档
标签
去牛客网
登录
/
注册
蛋黄酥饭的博客
全部文章
(共13篇)
题解 | 链表相交
class ListNode: def __init__(self, x): self.val = x self.next = None def getIntersectionNode(headA: ListNode, headB: ListNode) -...
2025-08-09
1
52
题解 | 平方根
# # 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可 # # 求非负整数 n 的平方根 # @param n int整型 你需要求 n 的平方根 # @return double浮点型 # import math class Solution: def findS...
2025-07-01
0
73
题解 | 矩阵转置
import sys n, m = map(int, input().split()) arr = list(input().split() for _ in range(n)) newarr = [["0"] *n for _ in range(m)] for i in r...
2025-06-28
0
77
题解 | 牛牛学数列6
import sys n = int(input()) f = [0,1,1] for i in range(3,n+1): f.append(f[i-1]+2*f[i-2]+f[i-3]) print(f[n-1])
2025-06-26
0
60
题解 | 数位之和
import sys n = list(map(int, input())) print(sum(n)) 字符串列表,变成数字列表
2025-06-26
0
51
题解 | 比大小
import sys a, b = map(int, input().split()) print("<" if a<b else "=" if a == b else ">")
2025-06-26
0
66
题解 | 小乐乐求和
from re import S import sys n = int(input()) print(n*(n+1)//2)
2025-06-25
0
67
题解 | 牛牛学立体
import sys a = list(map(int, input().split())) s = 2*(a[0]*a[1]+a[1]*a[2]+a[0]*a[2]) v = a[0]*a[1]*a[2] print(s,v,sep='\n')
2025-06-25
0
54
题解 | 绕距
import sys import math x1, y1= map(int, input().split()) x2, y2= map(int, input().split()) de = pow((pow(x1-x2, 2) + pow(y1-y2, 2)), 0.5) dm = abs(x1 ...
2025-06-24
0
52
题解 | 绕距
import sys import math x1, y1= map(int, input().split()) x2, y2= map(int, input().split()) de = pow((pow(x1-x2, 2) + pow(y1-y2, 2)), 0.5) dm = abs(x1 ...
2025-06-24
0
63
首页
上一页
1
2
下一页
末页