QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#75124#5236. Wersja dla profesjonalistów [A]XZTmaxsmall671 2ms3500kbC++23544b2023-02-04 15:38:472023-02-04 15:38:50

Judging History

你现在查看的是最新测评结果

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-02-04 15:38:50]
  • 评测
  • 测评结果:1
  • 用时:2ms
  • 内存:3500kb
  • [2023-02-04 15:38:47]
  • 提交

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,s="2["+s+"]")if(v&1)t=t+s;
	return t;
}
void work(int n)
{
	if(n==1)return void(cout<<"AE");
	if(n==2)return void(cout<<"AEACAEE");
	int a=n/2,b=(n-1)/2;work(a);work(b);
	string s=add("AC",b)+"A";
	string s1=add("CE",b)+"C"+add("A",b+1);
	string s2=add("E",a+b+1);
	cout<<s+add(s1,a)+s2;
}
signed main()
{
	cin>>n;
	if(n>1000)return 0;
	work(n);
	cout<<add("C",n);
	return 0;
}
/*
*/ 

詳細信息

Subtask #1:

score: 1
Accepted

Test #1:

score: 1
Accepted
time: 1ms
memory: 3416kb

input:

1

output:

AEC

result:

ok correct (length = 3)

Test #2:

score: 0
Accepted
time: 1ms
memory: 3404kb

input:

2

output:

AEACAEE2[C]

result:

ok correct (length = 13)

Test #3:

score: 0
Accepted
time: 2ms
memory: 3376kb

input:

4

output:

AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[C]]

result:

ok correct (length = 30)

Test #4:

score: 0
Accepted
time: 2ms
memory: 3336kb

input:

5

output:

AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]]C2[2[C]]

result:

ok correct (length = 43)

Test #5:

score: 0
Accepted
time: 2ms
memory: 3328kb

input:

6

output:

AEAEACACEC2[A]E2[E]AEACAEE2[AC]A2[CE]CA2[A]2[2[CE]CA2[A]]2[E]2[2[E]]2[C]2[2[C]]

result:

ok correct (length = 53)

Test #6:

score: 0
Accepted
time: 2ms
memory: 3360kb

input:

7

output:

AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]C2[C]2[2[C]]

result:

ok correct (length = 53)

Test #7:

score: 0
Accepted
time: 0ms
memory: 3464kb

input:

10

output:

AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]]AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[AC]]A2[2[CE]]CA2[2[A]]2[2[2[2[CE]]CA2[2[A]]]]2[E]2[2[2[E]]]2[C]2[2[2[C]]]

result:

ok correct (length = 79)

Test #8:

score: 0
Accepted
time: 1ms
memory: 3352kb

input:

69

output:

AEACAEEAEACA2[CEC2[A]]2[2[E]]AEAEACACEC2[A]E2[E]AC2[AC]A2[2[CE2[CE]C2[2[A]]]]2[2[2[E]]]AEACAEEAEACA2[CEC2[A]]2[2[E]]AEAEACACEC2[A]E2[E]AC2[AC]A2[2[CE2[CE]C2[2[A]]]]2[2[2[E]]]2[2[2[AC]]]A2[2[2[2[2[2[CE]]]CA2[2[2[A]]]]]]E2[2[2[2[E]]]]AEACAEEAEACA2[CEC2[A]]2[2[E]]AEAEACACEC2[A]E2[E]AC2[AC]A2[2[CE2[CE]C...

result:

ok correct (length = 277)

Test #9:

score: 0
Accepted
time: 0ms
memory: 3360kb

input:

100

output:

AEAEACACEC2[A]E2[E]AEACAEE2[AC]A2[CE]CA2[A]2[2[CE]CA2[A]]2[E]2[2[E]]AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]]AC2[2[AC]]A2[CE2[2[CE]]C2[A]2[2[A]]]2[2[CE2[2[CE]]C2[A]2[2[A]]]]2[2[E]]2[2[2[E]]]AEAEACACEC2[A]E2[E]AEACAEE2[AC]A2[CE]CA2[A]2[2[CE]CA2[A]]2[E]2[2[E]]AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]...

result:

ok correct (length = 312)

Test #10:

score: 0
Accepted
time: 2ms
memory: 3348kb

input:

101

output:

AEAEACACEC2[A]E2[E]AEACAEE2[AC]A2[CE]CA2[A]2[2[CE]CA2[A]]2[E]2[2[E]]AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]]AC2[2[AC]]A2[CE2[2[CE]]C2[A]2[2[A]]]2[2[CE2[2[CE]]C2[A]2[2[A]]]]2[2[E]]2[2[2[E]]]AEAEACACEC2[A]E2[E]AEACAEE2[AC]A2[CE]CA2[A]2[2[CE]CA2[A]]2[E]2[2[E]]AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]...

result:

ok correct (length = 321)

Test #11:

score: 0
Accepted
time: 2ms
memory: 3440kb

input:

250

output:

AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AC2[AC]2[2[AC]]ACE2[CE]2[2[CE]]C2[2[2[A]]]2[CE2[CE]2[2[CE]]C2[2[2[A]]]]2[2[CE2[CE]2[2[CE]]C2[2[2[A]]]]]E2[E]2[2[E]]2[2...

result:

ok correct (length = 526)

Test #12:

score: 0
Accepted
time: 0ms
memory: 3344kb

input:

251

output:

AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AC2[AC]2[2[AC]]ACE2[CE]2[2[CE]]C2[2[2[A]]]2[CE2[CE]2[2[CE]]C2[2[2[A]]]]2[2[CE2[CE]2[2[CE]]C2[2[2[A]]]]]E2[E]2[2[E]]2[2...

result:

ok correct (length = 456)

Test #13:

score: 0
Accepted
time: 2ms
memory: 3368kb

input:

252

output:

AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AC2[AC]2[2[AC]]ACE2[CE]2[2[CE]]C2[2[2[A]]]2[CE2[CE]2[2[CE]]C2[2[2[A]]]]2[2[CE2[CE]2[2[CE]]C2[2[2[A]]]]]E2[E]2[2[E]]2[2...

result:

ok correct (length = 479)

Test #14:

score: 0
Accepted
time: 2ms
memory: 3340kb

input:

299

output:

AEACAEEAEACA2[CEC2[A]]2[2[E]]AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[AC]]A2[2[2[2[CE]]CA2[2[A]]]]E2[2[2[E]]]AEACAEEAEACA2[CEC2[A]]2[2[E]]AEAEACACEC2[A]E2[E]AC2[AC]A2[2[CE2[CE]C2[2[A]]]]2[2[2[E]]]2[2[2[AC]]]A2[2[2[CE]]]CA2[2[2[A]]]2[2[2[2[2[2[CE]]]CA2[2[2[A]]]]]]2[E]2[2[2[2[E]]]]AEACAEEAEACA2[CEC2[A]]2[2[E]...

result:

ok correct (length = 486)

Test #15:

score: 0
Accepted
time: 2ms
memory: 3500kb

input:

300

output:

AEACAEEAEACA2[CEC2[A]]2[2[E]]AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[AC]]A2[2[2[2[CE]]CA2[2[A]]]]E2[2[2[E]]]AEACAEEAEACA2[CEC2[A]]2[2[E]]AEAEACACEC2[A]E2[E]AC2[AC]A2[2[CE2[CE]C2[2[A]]]]2[2[2[E]]]2[2[2[AC]]]A2[2[2[CE]]]CA2[2[2[A]]]2[2[2[2[2[2[CE]]]CA2[2[2[A]]]]]]2[E]2[2[2[2[E]]]]AEACAEEAEACA2[CEC2[A]]2[2[E]...

result:

ok correct (length = 515)

Subtask #2:

score: 0
Wrong Answer

Test #16:

score: 1
Accepted
time: 0ms
memory: 3360kb

input:

320

output:

AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]]AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[AC]]A2[2[CE]]CA2[2[A]]2[2[2[2[CE]]CA2[2[A]]]]2[E]2[2[2[E]]]AEACAEEAEACA2[CEC2[A]]2[2[E]]AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[AC]]A2[2[2[2[CE]]CA2[2[A]]]]E2[2[2[E]]]AC2[2[2[AC]]]A2[CE2[2[2[CE]]]C2[A]2[2[2[A]]]]2[2[2[CE2[2[2[CE]]]C...

result:

ok correct (length = 555)

Test #17:

score: 0
Accepted
time: 2ms
memory: 3424kb

input:

321

output:

AEACAEEAEACAEE2[AC]A2[2[CE]CA2[A]]E2[2[E]]AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[AC]]A2[2[CE]]CA2[2[A]]2[2[2[2[CE]]CA2[2[A]]]]2[E]2[2[2[E]]]AEACAEEAEACA2[CEC2[A]]2[2[E]]AEACAEEAEACA2[CEC2[A]]2[2[E]]2[2[AC]]A2[2[2[2[CE]]CA2[2[A]]]]E2[2[2[E]]]AC2[2[2[AC]]]A2[CE2[2[2[CE]]]C2[A]2[2[2[A]]]]2[2[2[CE2[2[2[CE]]]C...

result:

ok correct (length = 507)

Test #18:

score: 0
Accepted
time: 1ms
memory: 3492kb

input:

1000

output:

AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AEAEACACEC2[A]E2[E]AEAEACACEC2[A]E2[E]AC2[AC]ACE2[CE]C2[2[A]]2[CE2[CE]C2[2[A]]]E2[E]2[2[E]]AC2[AC]2[2[AC]]ACE2[CE]2[2[CE]]C2[2[2[A]]]2[CE2[CE]2[2[CE]]C2[2[2[A]]]]2[2[CE2[CE]2[2[CE]]C2[2[2[A]]]]]E2[E]2[2[E]]2[2...

result:

ok correct (length = 809)

Test #19:

score: -1
Wrong Answer
time: 1ms
memory: 3320kb

input:

1024

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #3:

score: 0
Wrong Answer

Test #28:

score: 0
Wrong Answer
time: 2ms
memory: 3344kb

input:

1000000

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #4:

score: 0
Wrong Answer

Test #37:

score: 0
Wrong Answer
time: 2ms
memory: 3352kb

input:

999999

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #5:

score: 0
Wrong Answer

Test #46:

score: 0
Wrong Answer
time: 1ms
memory: 3340kb

input:

10000000000

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #6:

score: 0
Wrong Answer

Test #55:

score: 0
Wrong Answer
time: 1ms
memory: 3276kb

input:

9999999999

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #7:

score: 0
Wrong Answer

Test #64:

score: 0
Wrong Answer
time: 2ms
memory: 3276kb

input:

100000000000000

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #8:

score: 0
Wrong Answer

Test #84:

score: 0
Wrong Answer
time: 1ms
memory: 3388kb

input:

99999999999999

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #9:

score: 0
Wrong Answer

Test #103:

score: 0
Wrong Answer
time: 1ms
memory: 3328kb

input:

1000000000000000000

output:


result:

wrong output format Unexpected end of file - token expected

Subtask #10:

score: 0
Wrong Answer

Test #128:

score: 0
Wrong Answer
time: 2ms
memory: 3340kb

input:

999999999999999999

output:


result:

wrong output format Unexpected end of file - token expected