QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#95970 | #5575. Knight's Tour Redux | aguo123 | AC ✓ | 18ms | 5968kb | C++14 | 1.6kb | 2023-04-12 19:07:19 | 2023-04-12 19:07:20 |
Judging History
answer
#include<iostream>
#include<string>
#include <cstring>
#include <vector>
#include<algorithm>
using namespace std;
typedef long long LL;
typedef pair<int,int> PII;
const LL N=1e6+10,mod=998244353;
int n;
int m;
string s;
int a[1000010];
LL cnt1[200],cnt2[200];
bool col[N],row[N];
int num,vis;
vector<PII>ans;
int dx[]={1,3,3,1,-1,-3,-3,-1},dy[]={3,1,-1,-3,-3,-1,1,3};
void dfs(int x,int y){
if(vis)return;
if(x<1||x>n||y<1||y>n)return;
if(col[x]||row[y])return;
num++;
col[x]=row[y]=1;
ans.push_back({x,y});
if(num==n){
for(auto k:ans)
printf("%d %d\n",k.first,k.second);
vis=1;
return ;
}
for(int i=0;i<8;i++)
dfs(x+dx[i],y+dy[i]);
col[x]=row[y]=0;
num--;
ans.pop_back();
}
int main()
{ //LL ans=0;
cin>>n;
if(n==1){
// puts("POSSIBLE");
printf("POSSIBLE\n");
printf("1 1\n");
return 0;
}else if(n<5){ printf("IMPOSSIBLE\n");;return 0;}
cout<<"POSSIBLE"<<endl;
int pos=0;
while(pos+18<n){
printf("%d %d\n",pos+1,pos+3);
printf("%d %d\n",pos+4,pos+2);
printf("%d %d\n",pos+7,pos+1);
printf("%d %d\n",pos+6,pos+4);
printf("%d %d\n",pos+3,pos+5);
printf("%d %d\n",pos+2,pos+8);
printf("%d %d\n",pos+5,pos+7);
printf("%d %d\n",pos+8,pos+6);
printf("%d %d\n",pos+9,pos+9);
for(int i=1;i<=9;i++)col[pos+i]=row[pos+i]=1,num++;
pos+=9;
}
dfs(pos+1,pos+3);
return 0;
}
詳細信息
Test #1:
score: 100
Accepted
time: 1ms
memory: 3496kb
input:
1
output:
POSSIBLE 1 1
result:
ok answer = 1
Test #2:
score: 0
Accepted
time: 2ms
memory: 3444kb
input:
2
output:
IMPOSSIBLE
result:
ok answer = 0
Test #3:
score: 0
Accepted
time: 0ms
memory: 3616kb
input:
3
output:
IMPOSSIBLE
result:
ok answer = 0
Test #4:
score: 0
Accepted
time: 2ms
memory: 3416kb
input:
4
output:
IMPOSSIBLE
result:
ok answer = 0
Test #5:
score: 0
Accepted
time: 2ms
memory: 3560kb
input:
5
output:
POSSIBLE 1 3 4 4 5 1 2 2 3 5
result:
ok answer = 1
Test #6:
score: 0
Accepted
time: 0ms
memory: 3564kb
input:
6
output:
POSSIBLE 1 3 2 6 5 5 6 2 3 1 4 4
result:
ok answer = 1
Test #7:
score: 0
Accepted
time: 2ms
memory: 3568kb
input:
7
output:
POSSIBLE 1 3 2 6 5 7 6 4 7 1 4 2 3 5
result:
ok answer = 1
Test #8:
score: 0
Accepted
time: 2ms
memory: 3544kb
input:
8
output:
POSSIBLE 1 3 2 6 5 7 8 8 7 5 6 2 3 1 4 4
result:
ok answer = 1
Test #9:
score: 0
Accepted
time: 0ms
memory: 3580kb
input:
9
output:
POSSIBLE 1 3 2 6 3 9 6 8 9 7 8 4 7 1 4 2 5 5
result:
ok answer = 1
Test #10:
score: 0
Accepted
time: 1ms
memory: 3696kb
input:
10
output:
POSSIBLE 1 3 2 6 3 9 6 10 7 7 10 8 9 5 8 2 5 1 4 4
result:
ok answer = 1
Test #11:
score: 0
Accepted
time: 0ms
memory: 3564kb
input:
11
output:
POSSIBLE 1 3 4 4 5 7 2 8 3 11 6 10 9 9 10 6 7 5 8 2 11 1
result:
ok answer = 1
Test #12:
score: 0
Accepted
time: 2ms
memory: 3552kb
input:
12
output:
POSSIBLE 1 3 4 4 5 1 8 2 9 5 12 6 11 9 10 12 7 11 6 8 3 7 2 10
result:
ok answer = 1
Test #13:
score: 0
Accepted
time: 2ms
memory: 3556kb
input:
13
output:
POSSIBLE 1 3 2 6 5 7 4 4 3 1 6 2 7 5 8 8 9 11 12 12 13 9 10 10 11 13
result:
ok answer = 1
Test #14:
score: 0
Accepted
time: 2ms
memory: 3572kb
input:
14
output:
POSSIBLE 1 3 2 6 5 7 6 10 3 11 4 14 7 13 10 12 11 9 14 8 13 5 12 2 9 1 8 4
result:
ok answer = 1
Test #15:
score: 0
Accepted
time: 2ms
memory: 3516kb
input:
15
output:
POSSIBLE 1 3 2 6 3 9 6 10 7 13 4 12 5 15 8 14 9 11 10 8 13 7 14 4 15 1 12 2 11 5
result:
ok answer = 1
Test #16:
score: 0
Accepted
time: 0ms
memory: 3568kb
input:
16
output:
POSSIBLE 1 3 2 6 3 9 4 12 5 15 8 16 9 13 6 14 7 11 10 10 11 7 14 8 15 5 16 2 13 1 12 4
result:
ok answer = 1
Test #17:
score: 0
Accepted
time: 0ms
memory: 3516kb
input:
17
output:
POSSIBLE 1 3 2 6 3 9 6 8 5 5 4 2 7 1 8 4 9 7 10 10 11 13 12 16 15 17 16 14 17 11 14 12 13 15
result:
ok answer = 1
Test #18:
score: 0
Accepted
time: 2ms
memory: 3740kb
input:
18
output:
POSSIBLE 1 3 2 6 3 9 4 12 7 13 8 16 5 15 6 18 9 17 10 14 11 11 14 10 15 7 18 8 17 5 16 2 13 1 12 4
result:
ok answer = 1
Test #19:
score: 0
Accepted
time: 0ms
memory: 5608kb
input:
19
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 11 15 12 18 15 19 16 16 19 17 18 14 17 11 14 10 13 13
result:
ok answer = 1
Test #20:
score: 0
Accepted
time: 2ms
memory: 3564kb
input:
20
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 13 14 16 11 17 12 20 15 19 18 18 19 15 16 14 17 11 20 10
result:
ok answer = 1
Test #21:
score: 0
Accepted
time: 12ms
memory: 3944kb
input:
99990
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #22:
score: 0
Accepted
time: 11ms
memory: 3768kb
input:
99991
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #23:
score: 0
Accepted
time: 10ms
memory: 5688kb
input:
99992
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #24:
score: 0
Accepted
time: 3ms
memory: 3776kb
input:
99993
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #25:
score: 0
Accepted
time: 8ms
memory: 5900kb
input:
99994
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #26:
score: 0
Accepted
time: 18ms
memory: 5732kb
input:
99995
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #27:
score: 0
Accepted
time: 9ms
memory: 3752kb
input:
99996
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #28:
score: 0
Accepted
time: 11ms
memory: 5712kb
input:
99997
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #29:
score: 0
Accepted
time: 2ms
memory: 5716kb
input:
99998
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #30:
score: 0
Accepted
time: 17ms
memory: 5760kb
input:
99999
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #31:
score: 0
Accepted
time: 12ms
memory: 3780kb
input:
100000
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #32:
score: 0
Accepted
time: 7ms
memory: 3740kb
input:
74615
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #33:
score: 0
Accepted
time: 5ms
memory: 3556kb
input:
25027
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #34:
score: 0
Accepted
time: 8ms
memory: 5656kb
input:
40852
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #35:
score: 0
Accepted
time: 4ms
memory: 5664kb
input:
31411
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #36:
score: 0
Accepted
time: 7ms
memory: 5672kb
input:
37332
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #37:
score: 0
Accepted
time: 8ms
memory: 5872kb
input:
80435
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #38:
score: 0
Accepted
time: 12ms
memory: 3692kb
input:
90457
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #39:
score: 0
Accepted
time: 2ms
memory: 5596kb
input:
1796
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #40:
score: 0
Accepted
time: 12ms
memory: 5600kb
input:
55809
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #41:
score: 0
Accepted
time: 7ms
memory: 5964kb
input:
97013
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #42:
score: 0
Accepted
time: 8ms
memory: 5716kb
input:
77938
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #43:
score: 0
Accepted
time: 15ms
memory: 5968kb
input:
87884
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #44:
score: 0
Accepted
time: 5ms
memory: 3676kb
input:
61687
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #45:
score: 0
Accepted
time: 2ms
memory: 5584kb
input:
32567
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #46:
score: 0
Accepted
time: 2ms
memory: 5664kb
input:
53441
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #47:
score: 0
Accepted
time: 5ms
memory: 3584kb
input:
19197
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #48:
score: 0
Accepted
time: 13ms
memory: 5696kb
input:
77260
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #49:
score: 0
Accepted
time: 3ms
memory: 5552kb
input:
6699
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #50:
score: 0
Accepted
time: 5ms
memory: 5628kb
input:
72561
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #51:
score: 0
Accepted
time: 8ms
memory: 5612kb
input:
60412
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #52:
score: 0
Accepted
time: 13ms
memory: 3848kb
input:
78243
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #53:
score: 0
Accepted
time: 4ms
memory: 3688kb
input:
93055
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #54:
score: 0
Accepted
time: 1ms
memory: 3712kb
input:
72060
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #55:
score: 0
Accepted
time: 3ms
memory: 3576kb
input:
10561
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #56:
score: 0
Accepted
time: 10ms
memory: 5608kb
input:
56368
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #57:
score: 0
Accepted
time: 2ms
memory: 5716kb
input:
44898
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #58:
score: 0
Accepted
time: 12ms
memory: 5616kb
input:
69941
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #59:
score: 0
Accepted
time: 0ms
memory: 3624kb
input:
24192
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #60:
score: 0
Accepted
time: 4ms
memory: 5812kb
input:
13677
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #61:
score: 0
Accepted
time: 9ms
memory: 5824kb
input:
47780
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #62:
score: 0
Accepted
time: 7ms
memory: 5592kb
input:
36022
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #63:
score: 0
Accepted
time: 4ms
memory: 5668kb
input:
50675
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #64:
score: 0
Accepted
time: 5ms
memory: 3560kb
input:
26644
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #65:
score: 0
Accepted
time: 11ms
memory: 5692kb
input:
56969
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #66:
score: 0
Accepted
time: 10ms
memory: 5852kb
input:
53401
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #67:
score: 0
Accepted
time: 2ms
memory: 3540kb
input:
24772
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #68:
score: 0
Accepted
time: 2ms
memory: 3640kb
input:
35433
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #69:
score: 0
Accepted
time: 6ms
memory: 3916kb
input:
89877
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #70:
score: 0
Accepted
time: 13ms
memory: 5648kb
input:
99986
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1
Test #71:
score: 0
Accepted
time: 3ms
memory: 3580kb
input:
6094
output:
POSSIBLE 1 3 4 2 7 1 6 4 3 5 2 8 5 7 8 6 9 9 10 12 13 11 16 10 15 13 12 14 11 17 14 16 17 15 18 18 19 21 22 20 25 19 24 22 21 23 20 26 23 25 26 24 27 27 28 30 31 29 34 28 33 31 30 32 29 35 32 34 35 33 36 36 37 39 40 38 43 37 42 40 39 41 38 44 41 43 44 42 45 45 46 48 49 47 52 46 51 49 48 50 47 53 50 ...
result:
ok answer = 1