QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#75081#5236. Wersja dla profesjonalistów [A]stkwill0 2ms3716kbC++14651b2023-02-04 15:04:392023-02-04 15:05:00

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:05:00]
  • 评测
  • 测评结果:0
  • 用时:2ms
  • 内存:3716kb
  • [2023-02-04 15:04:39]
  • 提交

answer

#include <bits/stdc++.h>

using int64 = long long;

const int N = 200005;

inline void Solve(int64 n) {
    if (n == 1) return void(printf("AC"));
    if (n == 2) return void(printf("AACECAC"));
    if (!(n & 1)) return printf("%lld[A]%lld[CE]C", n, n - 1), Solve(n - 1);
    int k = n / 2;
    printf("2["), Solve(k), printf("]");
    printf("%lld[AE]A", k);
    printf("%lld[%lld[EC]E%lld[A]]", k, k, k + 1);
    printf("%lld[C]", n);
}

int main() {
    std::ios::sync_with_stdio(false);
    std::cin.tie(nullptr), std::cout.tie(nullptr);
    int64 n;
    std::cin >> n;
    Solve(n), printf("%lld[E]\n", n);
    return 0;
}

详细

Subtask #1:

score: 0
Wrong Answer

Test #1:

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

input:

1

output:

AC1[E]

result:

wrong answer incorrect path

Subtask #2:

score: 0
Wrong Answer

Test #16:

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

input:

320

output:

320[A]319[CE]C2[2[2[2[2[2[4[A]3[CE]C2[AC]1[AE]A1[1[EC]E2[A]]3[C]]4[AE]A4[4[EC]E5[A]]9[C]]9[AE]A9[9[EC]E10[A]]19[C]]19[AE]A19[19[EC]E20[A]]39[C]]39[AE]A39[39[EC]E40[A]]79[C]]79[AE]A79[79[EC]E80[A]]159[C]]159[AE]A159[159[EC]E160[A]]319[C]320[E]

result:

wrong answer invalid output

Subtask #3:

score: 0
Wrong Answer

Test #28:

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

input:

1000000

output:

1000000[A]999999[CE]C2[2[2[2[2[2[15624[A]15623[CE]C2[2[2[1952[A]1951[CE]C2[2[2[2[2[60[A]59[CE]C2[2[14[A]13[CE]C2[6[A]5[CE]C2[AACECAC]2[AE]A2[2[EC]E3[A]]5[C]]6[AE]A6[6[EC]E7[A]]13[C]]14[AE]A14[14[EC]E15[A]]29[C]]29[AE]A29[29[EC]E30[A]]59[C]]60[AE]A60[60[EC]E61[A]]121[C]]121[AE]A121[121[EC]E122[A]]243...

result:

wrong answer invalid output

Subtask #4:

score: 0
Wrong Answer

Test #37:

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

input:

999999

output:

2[2[2[2[2[2[15624[A]15623[CE]C2[2[2[1952[A]1951[CE]C2[2[2[2[2[60[A]59[CE]C2[2[14[A]13[CE]C2[6[A]5[CE]C2[AACECAC]2[AE]A2[2[EC]E3[A]]5[C]]6[AE]A6[6[EC]E7[A]]13[C]]14[AE]A14[14[EC]E15[A]]29[C]]29[AE]A29[29[EC]E30[A]]59[C]]60[AE]A60[60[EC]E61[A]]121[C]]121[AE]A121[121[EC]E122[A]]243[C]]243[AE]A243[243[E...

result:

wrong answer invalid output

Subtask #5:

score: 0
Wrong Answer

Test #46:

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

input:

10000000000

output:

10000000000[A]9999999999[CE]C2[2[2[2[2[2[2[2[2[2[1377016[A]1377015[CE]C2[2[2[172126[A]172125[CE]C2[86062[A]86061[CE]C2[43030[A]43029[CE]C2[21514[A]21513[CE]C2[10756[A]10755[CE]C2[2[2688[A]2687[CE]C2[2[2[2[2[2[2[20[A]19[CE]C2[2[4[A]3[CE]C2[AC]1[AE]A1[1[EC]E2[A]]3[C]]4[AE]A4[4[EC]E5[A]]9[C]]9[AE]A9[9[...

result:

wrong answer invalid output

Subtask #6:

score: 0
Wrong Answer

Test #55:

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

input:

9999999999

output:

2[2[2[2[2[2[2[2[2[2[1377016[A]1377015[CE]C2[2[2[172126[A]172125[CE]C2[86062[A]86061[CE]C2[43030[A]43029[CE]C2[21514[A]21513[CE]C2[10756[A]10755[CE]C2[2[2688[A]2687[CE]C2[2[2[2[2[2[2[20[A]19[CE]C2[2[4[A]3[CE]C2[AC]1[AE]A1[1[EC]E2[A]]3[C]]4[AE]A4[4[EC]E5[A]]9[C]]9[AE]A9[9[EC]E10[A]]19[C]]20[AE]A20[20[...

result:

wrong answer invalid output

Subtask #7:

score: 0
Time Limit Exceeded

Test #64:

score: 0
Time Limit Exceeded

input:

100000000000000

output:

100000000000000[A]99999999999999[CE]C2[2[-1004630016[A]-1004630017[CE]C2[-502315008[A]-502315009[CE]C2[-251157504[A]-251157505[CE]C2[-125578752[A]-125578753[CE]C2[-62789376[A]-62789377[CE]C2[-31394688[A]-31394689[CE]C2[-15697344[A]-15697345[CE]C2[-7848672[A]-7848673[CE]C2[-3924336[A]-3924337[CE]C2[-...

result:


Subtask #8:

score: 0
Time Limit Exceeded

Test #84:

score: 0
Time Limit Exceeded

input:

99999999999999

output:

2[2[-1004630016[A]-1004630017[CE]C2[-502315008[A]-502315009[CE]C2[-251157504[A]-251157505[CE]C2[-125578752[A]-125578753[CE]C2[-62789376[A]-62789377[CE]C2[-31394688[A]-31394689[CE]C2[-15697344[A]-15697345[CE]C2[-7848672[A]-7848673[CE]C2[-3924336[A]-3924337[CE]C2[-1962168[A]-1962169[CE]C2[-981084[A]-9...

result:


Subtask #9:

score: 0
Time Limit Exceeded

Test #103:

score: 0
Time Limit Exceeded

input:

1000000000000000000

output:

1000000000000000000[A]999999999999999999[CE]C2[2[-371654656[A]-371654657[CE]C2[-185827328[A]-185827329[CE]C2[-92913664[A]-92913665[CE]C2[-46456832[A]-46456833[CE]C2[-23228416[A]-23228417[CE]C2[-11614208[A]-11614209[CE]C2[-5807104[A]-5807105[CE]C2[-2903552[A]-2903553[CE]C2[-1451776[A]-1451777[CE]C2[-...

result:


Subtask #10:

score: 0
Time Limit Exceeded

Test #128:

score: 0
Time Limit Exceeded

input:

999999999999999999

output:

2[2[-371654656[A]-371654657[CE]C2[-185827328[A]-185827329[CE]C2[-92913664[A]-92913665[CE]C2[-46456832[A]-46456833[CE]C2[-23228416[A]-23228417[CE]C2[-11614208[A]-11614209[CE]C2[-5807104[A]-5807105[CE]C2[-2903552[A]-2903553[CE]C2[-1451776[A]-1451777[CE]C2[-725888[A]-725889[CE]C2[-362944[A]-362945[CE]C...

result: