Python理论最高时间空间复杂度
2025-12-20 16:25:00
发布于:广东
0阅读
0回复
0点赞
import sys, time
# 1. 占 118 MB 内存,留余量
SIZE = 118 * 1024 * 1024
SIZE += 60
mem = bytearray(SIZE)
# 2. 卡 0.95 s
start = time.perf_counter()
while time.perf_counter() - start < 0.9855:
pass
# 3. 读入输出
a, b = map(int, sys.stdin.readline().split())
print(a + b)
del mem
这里空空如也

有帮助,赞一个