QOJ.ac
QOJ
ID | 题目 | 提交者 | 结果 | 用时 | 内存 | 语言 | 文件大小 | 提交时间 | 测评时间 |
---|---|---|---|---|---|---|---|---|---|
#75105 | #5236. Wersja dla profesjonalistów [A] | XZTmaxsmall67 | 0 | 348ms | 3540kb | C++23 | 575b | 2023-02-04 15:28:54 | 2023-02-04 15:28:56 |
Judging History
answer
#include<bits/stdc++.h>
#define int long long
using namespace std;
int n;
string add(string s,int v)
{
string t="";
for(;v;v>>=1)if(v&1)t=t+s,s="2["+s+"]";
return t;
}
void work(int n)
{
if(n==1)return void(cout<<"AC");
if(n==2)return void(cout<<"ACAEACC");
int a=n/2,b=(n-1)/2;work(a);work(b);
string s=add("AE",b)+"A";
string s1=add("EC",b)+"E"+add("A",b);
string s2=add("B",a+b+1);
cout<<s+add(s1,a)+s2;;
}
signed main()
{
cin>>n;
work(n);
cout<<add("E",n);
return 0;
}
/*
A 右
B 右上
C 左上
D 左
E 左下
F 右下
*/
詳細信息
Subtask #1:
score: 0
Wrong Answer
Test #1:
score: 0
Wrong Answer
time: 2ms
memory: 3480kb
input:
1
output:
ACE
result:
wrong answer incorrect path
Subtask #2:
score: 0
Wrong Answer
Test #16:
score: 0
Wrong Answer
time: 2ms
memory: 3408kb
input:
320
output:
ACAEACCACAEACCAEAECEAB2[B]ACAEACCACAEAECEABAEAECEA2[ECEA]B2[B]ACAEACCACAEAECEABACAEACCACAEAECEABAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]ACAEACCACAEAECEABACAEACCACAEAECEABAEAECEAB2[B]ACAEACCACAEAECEABACAEACCACAEAECEABAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]AE2[AE]2[...
result:
wrong answer incorrect path
Subtask #3:
score: 0
Wrong Answer
Test #28:
score: 0
Wrong Answer
time: 343ms
memory: 3348kb
input:
1000000
output:
ACACAEAECEAB2[B]ACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACACAEAECEAB2[B]ACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]AE2[AE]2[2[AE]]AEC2[EC]2[2[EC]]EA2[A]2[2[A]]2[EC2[EC]2[2[EC]]EA2[A]2[2[A]]]2[2[EC2[EC]2[2[EC]]EA2[A]2[2[A]]]]B2[B]2[2[B]]2[2[2[B]]]ACACAEA...
result:
wrong answer the length of your output (31430748) exceeds the constraint (150000)
Subtask #4:
score: 0
Wrong Answer
Test #37:
score: 0
Wrong Answer
time: 348ms
memory: 3540kb
input:
999999
output:
ACACAEAECEAB2[B]ACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACACAEAECEAB2[B]ACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]AE2[AE]2[2[AE]]AEC2[EC]2[2[EC]]EA2[A]2[2[A]]2[EC2[EC]2[2[EC]]EA2[A]2[2[A]]]2[2[EC2[EC]2[2[EC]]EA2[A]2[2[A]]]]B2[B]2[2[B]]2[2[2[B]]]ACACAEA...
result:
wrong answer the length of your output (31435571) exceeds the constraint (150000)
Subtask #5:
score: 0
Time Limit Exceeded
Test #46:
score: 0
Time Limit Exceeded
input:
10000000000
output:
ACAEACCACAEAECEABACAEACCACAEAECEABAEAECEAB2[B]ACAEACCACAEAECEABACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]BAEAECEA2[ECEA]B2[B]ACAEACCACAEAECEABACAEACCACAEAECEABAEAECEAB2[B]ACAEACCACAEAECEABACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]BAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACAEACCACAE...
result:
Subtask #6:
score: 0
Time Limit Exceeded
Test #55:
score: 0
Time Limit Exceeded
input:
9999999999
output:
ACAEACCACAEAECEABACAEACCACAEAECEABAEAECEAB2[B]ACAEACCACAEAECEABACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]BAEAECEA2[ECEA]B2[B]ACAEACCACAEAECEABACAEACCACAEAECEABAEAECEAB2[B]ACAEACCACAEAECEABACACAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]BAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACAEACCACAE...
result:
Subtask #7:
score: 0
Time Limit Exceeded
Test #64:
score: 0
Time Limit Exceeded
input:
100000000000000
output:
ACAEACCACAEACCAEAECEAB2[B]ACAEACCACAEACCAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACAEACCACAEACCAEAECEAB2[B]ACAEACCACAEAECEABAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]2[2[EC2[EC]EA2[A]]]B2[B]2[2[B]]ACAEACCACAEACCAEAECEAB2[B]ACAEACCACAEACCAEAECEAB2[B]AE2[AE]AEC2[EC]EA...
result:
Subtask #8:
score: 0
Time Limit Exceeded
Test #84:
score: 0
Time Limit Exceeded
input:
99999999999999
output:
ACAEACCACAEACCAEAECEAB2[B]ACAEACCACAEACCAEAECEAB2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACAEACCACAEACCAEAECEAB2[B]ACAEACCACAEAECEABAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]2[2[EC2[EC]EA2[A]]]B2[B]2[2[B]]ACAEACCACAEACCAEAECEAB2[B]ACAEACCACAEACCAEAECEAB2[B]AE2[AE]AEC2[EC]EA...
result:
Subtask #9:
score: 0
Time Limit Exceeded
Test #103:
score: 0
Time Limit Exceeded
input:
1000000000000000000
output:
ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]AE2[AE]2[2[AE]]AEC2[EC]2[2[EC]]EA2...
result:
Subtask #10:
score: 0
Time Limit Exceeded
Test #128:
score: 0
Time Limit Exceeded
input:
999999999999999999
output:
ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]ACACAEAECEAB2[B]ACAEACCAEAECEA2[ECEA]B2[B]AE2[AE]AEC2[EC]EA2[A]2[EC2[EC]EA2[A]]B2[B]2[2[B]]AE2[AE]2[2[AE]]AEC2[EC]2[2[EC]]EA2...