QOJ.ac
QOJ
ID | Problem | Submitter | Result | Time | Memory | Language | File size | Submit time | Judge time |
---|---|---|---|---|---|---|---|---|---|
#700461 | #7619. Make SYSU Great Again I | Arkhell | WA | 0ms | 3740kb | C++14 | 671b | 2024-11-02 13:02:13 | 2024-11-02 13:02:14 |
Judging History
answer
#include<bits/stdc++.h>
#define int long long
using namespace std;
int n,k;
map<pair<int,int>,int>mp;
void solve(){
cin>>n>>k;
for(int i=1;i<n;i++){
cout<<i<<' '<<i<<'\n';
cout<<i<<' '<<i+1<<'\n';
}
cout<<n<<' '<<n<<'\n';
cout<<n<<' '<<1<<'\n';
int nowx=1;
int nowy=3;
for(int i=2*n+1;i<=k;i++){
cout<<nowx<<' '<<nowy<<'\n';
nowy++;
if(nowx==nowy||nowx+1==nowy){
nowy++;
}
if(nowy>n){
nowx++;
nowy=1;
}
}
}
signed main(){
ios::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
solve();
}
Details
Tip: Click on the bar to expand more detailed information
Test #1:
score: 100
Accepted
time: 0ms
memory: 3668kb
input:
3 6
output:
1 1 1 2 2 2 2 3 3 3 3 1
result:
ok The answer is correct.
Test #2:
score: 0
Accepted
time: 0ms
memory: 3688kb
input:
3 7
output:
1 1 1 2 2 2 2 3 3 3 3 1 1 3
result:
ok The answer is correct.
Test #3:
score: 0
Accepted
time: 0ms
memory: 3740kb
input:
2 4
output:
1 1 1 2 2 2 2 1
result:
ok The answer is correct.
Test #4:
score: -100
Wrong Answer
time: 0ms
memory: 3672kb
input:
3 9
output:
1 1 1 2 2 2 2 3 3 3 3 1 1 3 2 1 2 3
result:
wrong answer The answer is wrong: Multiple numbers filled in a grid.