QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#302751 | #2549. King's Palace | chaoshxxu | WA | 1ms | 3428kb | C++20 | 219b | 2024-01-11 11:05:32 | 2024-01-11 11:05:32 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
int main() {
int n; cin>>n;
while (n--) {
long long a; cin>>a;
double d = sqrt(1 + 8*a);
long long b = (d-1)/2;
cout<<b<<"\n";
}
}
详细
Test #1:
score: 0
Wrong Answer
time: 1ms
memory: 3428kb
input:
2 3 1 R 2 R 1 G 2 R 1 B 2 G
output:
2 1
result:
wrong answer expected '6', found '2'