QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#75128#5236. Wersja dla profesjonalistów [A]XZTmaxsmall670 2ms3452kbC++23525b2023-02-04 15:42:312023-02-04 15:42:33

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:42:33]
  • 评测
  • 测评结果:0
  • 用时:2ms
  • 内存:3452kb
  • [2023-02-04 15:42:31]
  • 提交

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

Details

Tip: Click on the bar to expand more detailed information

Subtask #1:

score: 0
Wrong Answer

Test #1:

score: 1
Accepted
time: 2ms
memory: 3324kb

input:

1

output:

AEC

result:

ok correct (length = 3)

Test #2:

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

input:

2

output:

AEACAEE2[C]

result:

ok correct (length = 13)

Test #3:

score: -1
Wrong Answer
time: 2ms
memory: 3324kb

input:

4

output:

AEACACEC2[A]2[2[E]]2[2[C]]

result:

wrong answer incorrect path

Subtask #2:

score: 0
Wrong Answer

Test #16:

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

input:

320

output:

AEACACEC2[A]2[2[E]]2[2[AC]]A2[2[2[2[CE]]CA2[2[A]]]]E2[2[2[E]]]AC2[2[2[AC]]]ACE2[2[2[CE]]]C2[A]2[2[2[A]]]2[2[2[CE2[2[2[CE]]]C2[A]2[2[2[A]]]]]]E2[E]2[2[2[2[E]]]]AC2[AC]2[2[2[2[AC]]]]ACE2[CE]2[2[2[2[CE]]]]C2[2[A]]2[2[2[2[A]]]]2[CE2[CE]2[2[2[2[CE]]]]C2[2[A]]2[2[2[2[A]]]]]2[2[2[2[CE2[CE]2[2[2[2[CE]]]]C2[...

result:

wrong answer incorrect path

Subtask #3:

score: 0
Wrong Answer

Test #28:

score: 0
Wrong Answer
time: 0ms
memory: 3320kb

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: 0ms
memory: 3396kb

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: 2ms
memory: 3328kb

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: 2ms
memory: 3396kb

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: 3320kb

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: 3452kb

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: 3312kb

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: 0ms
memory: 3400kb

input:

999999999999999999

output:


result:

wrong output format Unexpected end of file - token expected