Alireza_OLY's blog

By Alireza_OLY, history, 8 months ago, In English

Hello guys I am stuck in solving the problem of "E-singer's tour". I am solving it using O(n) but I have no idea why it gets me a TLE error. Even though getting the input is O(n) and my code is O(n). I have no idea how to solve this problem. I even don't find any other way. my submission: https://codeforces.me/contest/1618/submission/249522519 my other submission that might have more optimization:https://codeforces.me/contest/1618/submission/249523839

  • Vote: I like it
  • -4
  • Vote: I do not like it

»
8 months ago, # |
  Vote: I like it +8 Vote: I do not like it

From your code:

lli b[4 * 10 * 100];
lli a[4 * 10 * 100];

From problem statement:

  • $$$1\leq n\leq 4\cdot10^4$$$
»
8 months ago, # |
  Vote: I like it -8 Vote: I do not like it

Wallah al-azim you are gay

  • »
    »
    8 months ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    Dalghake koskalake jolbak bas kon in kosnamak Bazi haro

    • »
      »
      »
      8 months ago, # ^ |
        Vote: I like it 0 Vote: I do not like it

      Kheili bi adabi kiram to adabet

    • »
      »
      »
      8 months ago, # ^ |
      Rev. 2   Vote: I like it 0 Vote: I do not like it

      Est-ce que c'est Nowruz? En 1403, sois plus poli.

      • »
        »
        »
        »
        8 months ago, # ^ |
          Vote: I like it 0 Vote: I do not like it

        Only English and Russian comments are allowed in codeforces.

        • »
          »
          »
          »
          »
          8 months ago, # ^ |
            Vote: I like it 0 Vote: I do not like it

          Weren't you talking finglish?! Rotab khordeh man'e rotab key konad?

          • »
            »
            »
            »
            »
            »
            8 months ago, # ^ |
              Vote: I like it 0 Vote: I do not like it

            Your proverb can be applied in criticizing all dalghak's manner, including his complaining of other's curiosity and being gay.