QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#220757 | #7178. Bishops | 123456qwe | WA | 1ms | 3424kb | C++14 | 442b | 2023-10-20 19:46:29 | 2023-10-20 19:46:29 |
Judging History
answer
#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define pb push_back
#define fi first
#define se second
const int N=1e6+10;
void solved()
{
ll n;cin>>n;
if (n==1)
{
cout<<1<<"\n";cout<<1<<" "<<1<<"\n";
}
cout<<n+n-2<<"\n";
for (int i=1;i<=n;i++) cout<<1<<" "<<i<<"\n";
for (int j=2;j<=n-1;j++) cout<<n<<" "<<j<<"\n";
}
int main()
{
ll t;cin>>t;
while(t--)
solved();
return 0;
}
詳細信息
Test #1:
score: 0
Wrong Answer
time: 1ms
memory: 3424kb
input:
2 5
output:
8 1 1 1 2 1 3 1 4 1 5 5 2 5 3 5 4 8 1 1 1 2 1 3 1 4 1 5 5 2 5 3 5 4
result:
wrong answer Integer parameter [name=q] equals to 8, violates the range [0, 7]