QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#520333#8777. Passport Stampshydrolyzed_Compile Error//C++14186b2024-08-15 13:01:462024-08-15 13:01:46

Judging History

你现在查看的是最新测评结果

  • [2024-08-15 13:01:46]
  • 评测
  • [2024-08-15 13:01:46]
  • 提交

answer

n, tot = map(int, input().split())

for i in range(1, n + 1):
    x = int(input())
    tot -= x - 1
    if (tot - 1) // x + 1 < i:
        print(i - 1)
        exit(0)
print(n)

Details

answer.code:1:1: error: ‘n’ does not name a type
    1 | n, tot = map(int, input().split())
      | ^