用户输出
1
系统信息
Exited with return code 0
编号 | 题目 | 状态 | 分数 | 总时间 | 内存 | 代码 / 答案文件 | 提交者 | 提交时间 |
---|---|---|---|---|---|---|---|---|
#2806 | #1002. 找倍数 | Wrong Answer | 20 | 937 ms | 2936 K | Python 3 / 448 B | t330034045 | 2023-11-21 20:59:35 |
def binary_search(n, k):
left, right = 0, 998244352
while left <= right:
mid = (left + right) // 2
x = n - 998244353 * k
if x == mid:
return mid
elif x < mid:
right = mid - 1
else:
left = mid + 1
return -1
n = int(input())
for k in range(-1000, 1000):
result = binary_search(n, k)
if result != -1:
print(result)
break
用户输出
998244349
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0
Special Judge 信息
Files user_out and answer differ
系统信息
Exited with return code 0