Блог пользователя One_touch_finish

Автор One_touch_finish, 9 лет назад, По-английски

Hello Codeforces,

Manthan, Codefest 16 will take place on Friday 26th February, 2016 10:35PM IST with a duration of 2.5 hours. The round is rated and consists of 8 problems.

The Department of Computer Science and Engineering is conducting Codefest from 25th-28th February. Manthan( मंथन in Hindi, meaning Brainstorming), the algorithmic programming contest under the banner of Codefest, is being held as a special Codeforces round. The round follows regular Codeforces rules. The prizes for Manthan are being sponsored by Walmart Labs.

The round is prepared by One_touch_finish, mkrjn99, FoolForCS, IITianUG and code_note.

We express our heartiest thanks to GlebsHP and AlexFetisov for their help in preparing the contest and MikeMirzayanov for the awesome Codeforces and Polygon platforms!

Prizes:

Don't forget to register for Manthan at our website also to be eligible for prizes.

Overall 1st place: ₹25,000 Overall 2nd place: ₹15,000 Overall 3rd place: ₹10,000

1st place in India: ₹15,000

1st place in IIT(BHU) Varanasi: ₹4,000 1st place in freshman year, IIT(BHU) Varanasi: ₹1,000

About Codefest: Citrix presents Codefest is the annual coding festival of the Department of Computer Science and Engineering, IIT (BHU) Varanasi, which is held online and is open to participation by all! Register on the Codefest website now! Free .tech domain for everyone who registers on the Codefest Website. Total prizes worth ₹450,000/- up for grabs with events covering domains from Math, Machine Learning Cryptography and Capture The Flag style competitions. Go to the Codefest website to find out more!

Update: The editorials have been posted: http://mirror.codeforces.com/blog/entry/43392

  • Проголосовать: нравится
  • +196
  • Проголосовать: не нравится

»
9 лет назад, # |
  Проголосовать: нравится +213 Проголосовать: не нравится

Regarding the prizes, I have a funny story from Manthan 2011 — five years back.

The announcement promised cash prizes to the top participants, and I ended up second. The page with the exact distribution of prizes is gone already, much as the whole Codefest'11 site, and the announcement does not list the details. Anyway, the contest was on March 13, 2011, and the results of this Codefest'11 track were finalized on March 16.

Then, in May 2011, it looks like no one got their prize yet (here is a relevant comment thread in Russian).

Long after, on September 13, 2012 (one and a half year after the contest), an email was sent by organizers to the top finishers, where they explained that they had technical difficulties, but the situation now improved, and now they are able to send 25% of the prizes in Amazon gift cards, as well as scanned certificates of achievement. Now, Amazon gift card is not exactly cash, but nevertheless, they held to this one and indeed sent the gift card and the certificate after a couple of days.

I haven't gotten any mail from them since, but who knows: maybe they will be able to send another 25% in a few years?..


The bottom line is, well, I don't actually expect to receive anything from the 2011 contest organizers anymore. But I really hope the 2016 organizers are more responsible.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +94 Проголосовать: не нравится

    Few days ago I received a T-Shirt from CodeChef for having a high place in a Long Challenge that took place at summer 2014. Hope that is not a common issue for Indian competitions :)

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +37 Проголосовать: не нравится

      Heh, I have not received any T-shirt from Codechef Cook-offs too! But that was also earlier than 2014. Maybe the situation improved since, or I am just not as lucky as you ;) .

      There were some Indian contests which actually managed to deliver some stuff to me (Bitwise comes to mind), so yes, it depends on the contest.

    • »
      »
      »
      9 лет назад, # ^ |
      Rev. 2   Проголосовать: нравится +25 Проголосовать: не нравится

      Related: see Egor's comment about ByteCode 2016, which just happens to be another Indian contest.

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +35 Проголосовать: не нравится

      Let me add my two cents. Some time ago, there was a series of three AI contests hosted by HackerEarth (Indian company) named "Battle of Bots". What do we have now:

      • Battle of Bots #1 (September 2015). I finished 4th, was promised a T-shirt, hasn't received it yet.
      • Battle of Bots #2 (November 2015). I finished 8th, was promised a T-shirt, hasn't received it yet.
      • IndiaHacks Bot Challenge (January 2016). I finished 15th, was promised the unknown gift voucher. Later it was announced that prizes will be awarded in May 2016. A little bit too long for a gift card, isn't it? :)

      Hope that is not a common issue for Indian competitions :)

      Unfortunately, you seem to be wrong :(

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +16 Проголосовать: не нравится

      I got mine within 3 weeks.. I guess it is an issue only for non-Indian participants..

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +103 Проголосовать: не нравится

    Last year jqdai0815,zhj and I took part in IOPC2015 on Codechef and got the first place. But so far we still have not received the prize which they promised.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +48 Проголосовать: не нравится

    Hi Ivan,
    I'm sorry you had such a negative experience the last time you participated. I apologize on behalf of the Codefest 2011 team, and can assure you that this will not happen again. In 2011, Codefest had faced some very serious difficulties due to which it had to eventually shutdown the same year.

    The situation has changed a lot and after 5 years, we are reviving the event with a completely different organization team. I hope you will have a good contest this time around. Rest assured, all the prizes will be delivered to the winners in time. All the best for the contest. :)

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +30 Проголосовать: не нравится

      Well, better luck to the organizers this time! Let's hope they really know what they are doing.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +70 Проголосовать: не нравится

    It definitely is a common issue for "Superpower by 2020".

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится -6 Проголосовать: не нравится

    It looks like this contest's results also going to like it :D

»
9 лет назад, # |
  Проголосовать: нравится -79 Проголосовать: не нравится

I would like to know whether GlebsHP and AlexFetisov have carefully checked the problem statements, data, etc. It's quite common in Indian contests that they make wrong data, write wrong statements, or even add a new problem during the contest.

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится +10 Проголосовать: не нравится

XD

»
9 лет назад, # |
  Проголосовать: нравится -15 Проголосовать: не нравится

2.5 hrs for 8 problems ? I don't know, seems a little though for Div.2 competitors.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +8 Проголосовать: не нравится

    Its literally tough for div2 people, because the contest will have both div1 and div2 people competing ;) i.e Its an open round for both divs !

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

I can not understand one thing, you are organizing 3 contest as HackerRank Collage rounds and one as regular CF round ?

Even I think that you are providing better prizes for winner of HR contest :)

I hope the size of code isn't important as on yesterday HR round :D

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Hi Aleksa, Yesterdays contest, viz Perplexed, was a constrained programming event, which was bound to have Code-Golf and TLE style problems. And for other 2 contests, CTF and Mathmania, Hackerrank is a good platform (where we have question and the answer, without code).

    However Manthan is the Algorithmic contest of Codefest. And associating it with Normal CF round makes it more obvious that Code Length etc are not that significant. Just the speed and the accuracy ;)

»
9 лет назад, # |
  Проголосовать: нравится +2 Проголосовать: не нравится

what will be the scoring distribution ?

»
9 лет назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

We must register at codefest.tech?

  • »
    »
    9 лет назад, # ^ |
    Rev. 3   Проголосовать: нравится 0 Проголосовать: не нравится

    Hi Alexandru, You need to register on www.codefest.tech to be eligible for prizes and to get a .tech domain free for 2 years. You can however, choose to not register and simply compete. :)

»
9 лет назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

Question from blind: russian texts?

»
9 лет назад, # |
  Проголосовать: нравится +7 Проголосовать: не нравится

Are the problems suitable for both divisions?

»
9 лет назад, # |
  Проголосовать: нравится +21 Проголосовать: не нравится

How can I get the ".tech" domain? I'm quite interested because it's not common to give out such things.

  • »
    »
    9 лет назад, # ^ |
    Rev. 4   Проголосовать: нравится +8 Проголосовать: не нравится

    Hey!

    The ".tech" domain will be made available to you via email. The moment you register here. In order to be eligible for receiving the ".tech" domain be sure to register with the same email that you intend to use for following up with the registration of the domain.

    The detailed instructions will be emailed to you!

    In case any one hasn't received the instructions but has registered on codefest.tech drop me a message with your email.

»
9 лет назад, # |
  Проголосовать: нравится -65 Проголосовать: не нравится

Is the contest rated?

»
9 лет назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

Register and get a .tech domain for free? that simple ? :P

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +5 Проголосовать: не нравится

    Hi!

    Yup! It is that simple! In order to be eligible for receiving the ".tech" domain be sure to register with the same email on our website that you intend to use while registering your free domain.

    Please note that the domain will be free for 2 years.

    .tech domains has partnered with Codefest for 2016 and made this offer to our participants. :)

»
9 лет назад, # |
  Проголосовать: нравится -22 Проголосовать: не нравится

will this round be rated ?

»
9 лет назад, # |
  Проголосовать: нравится +105 Проголосовать: не нравится

Let's forbid using words "rated" and "unrated" in comments.

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится +35 Проголосовать: не нравится

I probably shouldn't participate if I want to keep my rating, but fug it :DDDD.

Btw there are quite a lot less reds registered than in the last contest. Even when adjusted to the total number of participants.

»
9 лет назад, # |
  Проголосовать: нравится -14 Проголосовать: не нравится

Перенесите соревнование, я пожрать не успел!

»
9 лет назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

вот давайте без этого, мне вставать через 6 часов

»
9 лет назад, # |
  Проголосовать: нравится -9 Проголосовать: не нравится

Seriously? Delay? -_-

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

why the delay??? the site didn't break just before the contest start???

»
9 лет назад, # |
  Проголосовать: нравится -36 Проголосовать: не нравится

10 mins delay, seriously? F*ck this shit, I'm going to sleep :\

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится +7 Проголосовать: не нравится

before contest start: 3:12

one hour later

before contest start: 2:24

»
9 лет назад, # |
  Проголосовать: нравится -84 Проголосовать: не нравится

When I was at hacking ...

I think that he was not sure to include all of libraries.

»
9 лет назад, # |
  Проголосовать: нравится +6 Проголосовать: не нравится

For two hours I was trying to devise fast method to calculate factorial of 400009... and I did it!
What kind of brain malfunction is that?

»
9 лет назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

Now I know I am not the only one who completed Devil May Cry 4 recently .

As I saw the name of problem A I was like ' wait for it ' o.O

And when I saw the problem I was 'Hey' :v =D

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Yes but in the game you could break the shields of "The Savior" using rebellion and Ebony and Ivory do not do different damages :D

»
9 лет назад, # |
  Проголосовать: нравится +5 Проголосовать: не нравится

I see many hacks in this contest :D First time i was able to submit 4 problems that passed pretests. I wonder if backtracking would work under time limit for C :? I saw different solutions some using hashing in my room.

»
9 лет назад, # |
  Проголосовать: нравится +31 Проголосовать: не нравится

And again tourist in the last moment, awesome! :D

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

What was the pretest 4 of D ?

»
9 лет назад, # |
Rev. 3   Проголосовать: нравится +21 Проголосовать: не нравится

hacks on B,C,D in 15 minutes before end... Why are you doing this to me :(

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится +5 Проголосовать: не нравится

Can anyone tell why this test case is invalid for C?

3
aab
3
a
aa
ba
»
9 лет назад, # |
  Проголосовать: нравится +6 Проголосовать: не нравится

Hey guys I used a Trie Based solution for Problem 3...and I got MLE on pretest 10...Isin't that really unlucky?? I mean MLE??? why ????

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    If you're like me you used way more than 1,000,000 chars memory to store because you were storing prefixes to all of them. I don't even know if that's still a trie but it's what I did, when I hashed the strings it passed pretests but I have no faith in it.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    your memory = 262100 KB > memory limit per test: 256 megabytes

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      Ya I even wrote a question to the moderators asking them to increase the ML to 512 mbs out of desparation...Lol...

»
9 лет назад, # |
  Проголосовать: нравится +97 Проголосовать: не нравится

»
9 лет назад, # |
  Проголосовать: нравится +47 Проголосовать: не нравится

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

How to solve C?

  • »
    »
    9 лет назад, # ^ |
    Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

    pretty easy with hash and dp but needed to use a small mod in order not to use a map which would lead in to tl

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +8 Проголосовать: не нравится

      My solution is aproximate N*sqrt(Length of all words)*log(sqrt(n)) and I used a big mod. The main fact here is that there are at most Sqrt(lenght of all words) different lengths of words.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится -13 Проголосовать: не нравится

    I have solved C in this way:

    For every index i, make a new word up to the last index j, where the last word matched, and check the list, whether the word is listed or not.

    If the word is found in the list, then print the original word, otherwise ignore it. To find the newly made word in the list easily, I used a map<string, int> which keep the vector index of every original word.

    You can see my solution here: 16366352 For further query post your comment.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    My solution is trie. first reverse W's , then add them to trie.

    Then use dp , if suffix of s starting with position i can became partitioned with some of W's dp[i]=1 else dp[i]=0.

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится -13 Проголосовать: не нравится

Затупил в D, но зато от души взламывал B и C.

Обидно только, что А не получилось взломать... Видите ли:

for( int i = 0; i <= 10000; i ++ ) 
for( int j = 0; j <= 10000; j ++ ) 
if( i * a + j * b == c )
...

оптимизируется компилятором и работает менее 200 мс...

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +42 Проголосовать: не нравится

    Чему там оптимизироваться-то? 10^8 операций всего

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +11 Проголосовать: не нравится

    10^8 простых арифметических операций и так должны укладываться в 2 секунды. XXI век на дворе.

»
9 лет назад, # |
  Проголосовать: нравится +9 Проголосовать: не нравится

Why were the constraints so tight in C,D,E? :|

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Please discuss C and D.

In D, the sequence depends upon the 1st 2 numbers. So that's n^2. Then we must determine the sequence, adding an extra n which clearly times out. What is the correct approach? Is it using binary search?

In C, I thought KMP of all words on the text(10^9 complexity)and store all occurences in text. and then DP with the result. Again, very bad complexity.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    I used trie and greedy to solve problem C.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +10 Проголосовать: не нравится

    In C, I think you need to use trie.

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      Please elaborate.

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится +1 Проголосовать: не нравится

        If I had solved it then I could tell the process. That's why I said "I think".

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится 0 Проголосовать: не нравится

        Solve the entire dictionary in a trie. Now traversing the trie you can, in O(N) time determine all words that, when reversed, would be suffixes to the scrambled sentence.

        Now, for all prefixes of the scrambled sentence, in a similar manner you can also determine in O(N) time all words that, when reversed, would be suffixes to the prefix (essentially, substrings)

        Do this for all the prefixes sentence[:i], from longest to shortest, but if and only if there is a previously found substring or suffix that matches that prefix (that is in the form sentence[i:j]). That is essentially DP.

        Running time is O(N2)

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      I got MLE using Trie!!! MLE of all??

      • »
        »
        »
        »
        9 лет назад, # ^ |
        Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

        I got a MLE initially, but I optimized the trie so that each node has only 27 (initially NULL) children, not 128 for each ASCII character or something else bigger. This shouldn't give MLE because there are at most 1 000 000 nodes, each node taking up 224 bytes (27 64-bit pointers and two integers for depth and value). This gives definitely less than 256 MB, even after accounting for other things that need memory.

  • »
    »
    9 лет назад, # ^ |
    Rev. 3   Проголосовать: нравится +4 Проголосовать: не нравится

    IN D: Choose 1st and 2nd, n^2, and sequence is most log n , so O(n^2 log n)(check 1st and 2nd are 0 because if they are, sequence can be n)

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +4 Проголосовать: не нравится

    In D, I stored all checked pairs (and those which occured during generating the sequences in both directions) in set, thus sequences were not rechecked.

    In C, I used Trie. On reversed string, go char by char. Maintain set of possible places in Trie. When the node in Tree is end of some word, you branch (either continue word or start new word). But on each position you will branch at most once, because it does not matter which word has ended here, if there are multiple words possible.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится -13 Проголосовать: не нравится

    I have solved C in this way:

    For every index i, make a new word up to the last index j, where the last word matched, and check the list, whether the word is listed or not.

    If the word is found in the list, then print the original word, otherwise ignore it. To find the newly made word in the list easily, I used a map<string, int> which keep the vector index of every original word.

    You can see my solution here: 16366352 For further query post your comment.

»
9 лет назад, # |
  Проголосовать: нравится -8 Проголосовать: не нравится

In E, I used Sparse Tree for range min/max queries, building the two instances for 106 took almost 3 seconds (and the limit is 3 seconds).. Though anyway got WA.

»
9 лет назад, # |
  Проголосовать: нравится +146 Проголосовать: не нравится

Why this solution (for problem A) http://mirror.codeforces.com/contest/633/submission/16351079 is hacked? I really can't get it.

»
9 лет назад, # |
  Проголосовать: нравится +6 Проголосовать: не нравится

The difference between first two tasks and other tasks are big. I think that many solution for C and D won't pass final system testing (even I am not sure for my submissions).

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +5 Проголосовать: не нравится

    Pretests for D seem to be strong enough.

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +6 Проголосовать: не нравится

      Nope, they allow passing the solutions that try to start the sequence from all possible pairs of integers in the input (not only the distinct pairs). Such solutions are about to fail on test consisting of 1000 zeros (since the sequence length is linear for each starting pair).

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится +3 Проголосовать: не нравится

        By the way, do you know any other starting pair of numbers, other than 0 0, that allows very long sequence that does not reach large numbers quickly? I couldn't think of any other pair, but decided to start from unique pairs just in case.

        • »
          »
          »
          »
          »
          9 лет назад, # ^ |
            Проголосовать: нравится +3 Проголосовать: не нравится

          x -x

          • »
            »
            »
            »
            »
            »
            9 лет назад, # ^ |
              Проголосовать: нравится +3 Проголосовать: не нравится

            You are wrong. x, ( - x), 0, ( - x), ( - x), ( - 2x), ( - 3x), ( - 5x), ( - 8x), ....

        • »
          »
          »
          »
          »
          9 лет назад, # ^ |
            Проголосовать: нравится +14 Проголосовать: не нравится

          One can prove a bound of for the length of the sequence different from constant zero.

        • »
          »
          »
          »
          »
          9 лет назад, # ^ |
          Rev. 3   Проголосовать: нравится +1 Проголосовать: не нравится

          Maybe not really what you're looking for, but sequences can first decrease to smaller numbers, and then either stay at 0 or grow again.

          Fn,  - Fn - 1, Fn - 2,  - Fn - 3, ..., 3,  - 2, 1,  - 1, 0, ...

          EDIT: Fixed sequence, thanks Zlobober.

          • »
            »
            »
            »
            »
            »
            9 лет назад, # ^ |
              Проголосовать: нравится +5 Проголосовать: не нравится

             - 1 + 0 ≠ 0.

            • »
              »
              »
              »
              »
              »
              »
              9 лет назад, # ^ |
                Проголосовать: нравится +5 Проголосовать: не нравится

              Good point, in retrospect its obvious no sequence that starts with a nonzero value converges to zero.

              • »
                »
                »
                »
                »
                »
                »
                »
                9 лет назад, # ^ |
                  Проголосовать: нравится 0 Проголосовать: не нравится

                This is wrong — the longest possible sequence (the one reaching 2logφ109) does exactly that:

                13 -8 5 -3 2 -1 1 0 1 1 2 3 5 8 ...

                Or generally if your starting values are P and Q, then on N-th step you get Fn - 2 * P + Fn - 1 * Q, so if you set P = Fn - 1 and Q =  - Fn - 2, you will first reach 0 on n-th element, and then start growing from there.

                • »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  9 лет назад, # ^ |
                  Rev. 2   Проголосовать: нравится +15 Проголосовать: не нравится

                  I know, that's the sequence I gave a few posts above. By 'converge to zero' I mean the mathematical definition of convergence, so a sequence that just visits 0 once does not converge to 0.

                • »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  9 лет назад, # ^ |
                    Проголосовать: нравится 0 Проголосовать: не нравится

                  Converges  ≠  approaches.

      • »
        »
        »
        »
        9 лет назад, # ^ |
        Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

        I start from all possible pairs and it finishes in 160ms for 1000 zeroes on my laptop.

        edit: I just realized that I don't start from all possible pairs, haha.

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится -9 Проголосовать: не нравится

        That's evil! They should've added that test to pretests.

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      I hope so, but I saw some hacks with TLE. Also I didn't have brave to try some test like it :)

      Also I saw many strange solutions for C, many users don't have trie and even top guys wrote solution with it.

»
9 лет назад, # |
  Проголосовать: нравится +24 Проголосовать: не нравится

What is "Unexpected verdict"? I get it when I'm using a large random test case (http://ideone.com/oRhDoe) to hack C.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    We are investigating this issue, I will reply you as soon we will find out the problem.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +3 Проголосовать: не нравится

    I think it's because the input data you generated don't have a valid outcome while in the problem it says it's guaranteed to have at least one valid answer?

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +2 Проголосовать: не нравится

      Then the verdict should be "invalid input", not "unexpected".

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится 0 Проголосовать: не нравится

        I think the validator didn't check whether the input has a valid solution or not, so it unfortunately validated the input as correct, but the model solution couldn't make an answer, therefore "unexpected verdict" :p?

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +13 Проголосовать: не нравится

    It's ok now. I have investigated that everything is correct and may now conclude that what happened is: your test broke one of solutions we considered to be correct.

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +57 Проголосовать: не нравится

      Does that mean you will run the system test now or what :'D

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится +39 Проголосовать: не нравится

      Ironically, this case becomes the only one that cause my program WA (by hash collide).

      So I got -1200 points by this successful hack.

»
9 лет назад, # |
  Проголосовать: нравится +8 Проголосовать: не нравится

When will the Editorials come?

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится +23 Проголосовать: не нравится

Why drain of points was not adjusted to the contest length (as during Goodbye 2015)? I got less points for E (which I needed more than 1 hour for) than D (which I needed few minutes for).

»
9 лет назад, # |
  Проголосовать: нравится +73 Проголосовать: не нравится

Image and video hosting by TinyPic.

»
9 лет назад, # |
  Проголосовать: нравится +5 Проголосовать: не нравится

Why pending so long?

»
9 лет назад, # |
  Проголосовать: нравится +5 Проголосовать: не нравится

Why so much delay in System Testing? :(

»
9 лет назад, # |
Rev. 4   Проголосовать: нравится 0 Проголосовать: не нравится

I can't find the contest on the contest page anymore... Obviously you can still find it with the URL (/contests/633).

EDIT : maybe they have enough of people refreshing the standings page. :P

EDIT2 : fixed

»
9 лет назад, # |
  Проголосовать: нравится -83 Проголосовать: не нравится

i think this will be unrated because of unexpected behaviour during hacks

»
9 лет назад, # |
  Проголосовать: нравится +26 Проголосовать: не нравится

not unrated.. please...

»
9 лет назад, # |
Rev. 3   Проголосовать: нравится +112 Проголосовать: не нравится

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится +1 Проголосовать: не нравится

anyone who hacked was lucky :) i think the best way is that hackers get their hack points and the ones who got hacked because of this get their points back too

»
9 лет назад, # |
  Проголосовать: нравится +29 Проголосовать: не нравится

I hope the contest won't become unrated just because of 14 hacks. But, then again, for those 14 it will be unfair. Can't just those 14 people who were hacked be unrated? Since there are a lot of participation, I think it will be unfair to the other participants. Of course, if those 14 want to be rated, then its a different matter :) . I hope the contest organizers will take steps that will be fair for all.

»
9 лет назад, # |
  Проголосовать: нравится +40 Проголосовать: не нравится

Not sure if I should go to sleep and see the result tomorrow or wait for system test. . .

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится
»
9 лет назад, # |
  Проголосовать: нравится -26 Проголосовать: не нравится

It was a nice contest! LOL!
Thanks for really fast system testing and fast editorial! LOL!
Thanks for being on time and no delay! LOL!
Thanks for anything!

»
9 лет назад, # |
  Проголосовать: нравится -58 Проголосовать: не нравится

It was unfortunate I seem to have been deprived a chance to hack solutions. The hacking phase was on, yet there was no lock button to lock my solution :(

Image and video hosting by TinyPic

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +28 Проголосовать: не нравится

    Well, none of us have ever seen "Pending system testing" and a lock on the same page have we :)

»
9 лет назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

A few days ago, I wished the rating changes was announced fast. Today I am tired of waiting for the system testing

»
9 лет назад, # |
  Проголосовать: нравится +10 Проголосовать: не нравится

Plz just say when system tesing is running?? TIME LIMIT EXCEEDED!

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится +213 Проголосовать: не нравится

Hello everybody! As you may see the systests haven't yet started, let me explain you the reason.

Issue: during the contest we have noticed the mistake in the validator for problem A (Ebony and Ivory). It accepted tests with parameter c up to 100k, instead of 10k limitation given in the statement.

Scale of the problem: 19 hacks.

Decision: we have tried to find the most "fair" way to resolve this issue. Decision is the following:

  1. If the hack was unsuccessful, do nothing.

  2. If the hack was successful, but the solution was incorrect anyway, and could be hacked removing the extra sign, do nothing. For example, if the test was "1 1 100000", but the solution will obviously fail on test "1 1 10000", when we decided to keep thing as they are, as this is fair both for hacker (he still has his points) and the person being hacked (he knows his solution is incorrect).

  3. If the hack was successful, but the solution was actually correct, then we ignore this hack and rejudge the solution (so it becomes correct).

  4. We can't give you back the time that you have wasted on trying to figure out, why the solution was incorrect. The only thing we can do here is to apologize and make the round unrated for you, if you want it. So, if case number 3 is about you and you want the round to be unrated for you, contact me directly.

We sincerely apologize for this happening. As you see, we did our best to solve this issue in a way suitable for everybody.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +27 Проголосовать: не нравится

    I am sorry if I am inconveniencing you, but I think it would be best if you pm those individuals. After all, some of them might not be following this thread.

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится -24 Проголосовать: не нравится

      suppose I don't follow the thread . what does it mean --> I don't care about the contest :D

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится +7 Проголосовать: не нравится

        Not really. They may have gone to sleep, or to their school, or to do some errand. Not everybody has the time to stare idly at the computer screen, cross their fingers, and pray "please don't fail system test".

        • »
          »
          »
          »
          »
          9 лет назад, # ^ |
            Проголосовать: нравится 0 Проголосовать: не нравится

          again :

          when they came back , if the contest is important for them , they will check the thread :D

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +19 Проголосовать: не нравится

    That means system test is about to begin, right?

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +5 Проголосовать: не нравится

    In point 4, not sure why case 2 people will be aggrieved? They are after all getting a chance to check their solutions again, which was anyway incorrect (albeit from a wrong hack). But their solutions were incorrect, so rather they should be happy :P

    I think the case 3 people would feel aggrieved, as they wasted time unnecessarily mulling over why they got hacked for a correct solution.

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      Sure thing it must be case number 3

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится 0 Проголосовать: не нравится

        Cool :)

        I am none of these cases btw. Was simply analyzing the solution. Pretty elegant one. Should suit nearly everybody :)

»
9 лет назад, # |
  Проголосовать: нравится +47 Проголосовать: не нравится

Please tell us when the system test gonna start :(

»
9 лет назад, # |
Rev. 3   Проголосовать: нравится +3 Проголосовать: не нравится

Could someone please explain how can Java 8 use 0 KB memory for the problem C? It seems strange for me considering that in C++ I myself got MLE on it :( Edit: The solutions in Java 8 either use 100MB+ or 0.

»
9 лет назад, # |
  Проголосовать: нравится +8 Проголосовать: не нравится

How to solve H?

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +10 Проголосовать: не нравится

    The expected solution was using MO's Algorithm.

  • »
    »
    9 лет назад, # ^ |
    Rev. 2   Проголосовать: нравится +8 Проголосовать: не нравится

    I think that O(n * q) solution is OK.

    UPD. He got WA due to overflow. Now, it's OK, 4929 ms.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    If are being blocked from seeing accepted solutions before System tests. Find any user who accepted this problem, add him as a friend, go to friend standings, click on his submission, and you shall be able to see his/her solution.

    As for your question, It looks like Tourist solved it using Mo's Algorithm.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +13 Проголосовать: не нравится

    We can use Mo's algorithm to reduce the problem to the operations of adding or removing an integer to a set and update the sum. We can keep the set and sums in a range using a treap.

    To update Σi = 0nFj × aj when adding x at position j, we need to add Fj × x and "shift" Σj = inFj × aj to Σj = inFj + 1 × aj. To be able to "shift" sums like that, we store both Σj = inFj × aj and Σj = inFj + 1 × aj, as we can then easily compute all Σj = inFj + k × aj.

    My code (the important functions are push, update, insert and remove) : http://lpaste.net/8369132792918835200

    The complexity should be O(n sqrt(n) log(n))

»
9 лет назад, # |
  Проголосовать: нравится +46 Проголосовать: не нравится

Come on, start these systests. We all want to get our TLEs and go to bed.

»
9 лет назад, # |
  Проголосовать: нравится +9 Проголосовать: не нравится

It's almost 12 PM in my country. Am I going to know whether my solutions will pass before going to sleep? :(

»
9 лет назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

Finally!

»
9 лет назад, # |
  Проголосовать: нравится +12 Проголосовать: не нравится

At last our long desired system testing started !

»
9 лет назад, # |
  Проголосовать: нравится +12 Проголосовать: не нравится

Hashing fails for C :(

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    my hashing soluion for C passed

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится -8 Проголосовать: не нравится

      Congrats for picking the right constants :p

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится 0 Проголосовать: не нравится

        I picked the right constants and used double hashing, still got WA. Got Accepted after replacing one random prime with another. Also got WA in H just because of forgetting one MOD operation. What kind of hellish misfortune is this?

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +3 Проголосовать: не нравится

    My hashing + dp passed :D

»
9 лет назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

Black day II?

»
9 лет назад, # |
  Проголосовать: нравится +4 Проголосовать: не нравится

Why are the system tests stuck at 72% ?

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Why and how every time the score of the problems in contest was changing?

I noticed : 1. When contest started score of Problem E was 250, so I started doing that. 2. Then after a refresh, score of Problem A 750 and E was still 250. 3. Then A became of 500 then it became of 250 now at the time of systests it is of 500! 4. Score of other problems also changed.

Is this legit during contest?

Wrong validator/test cases can be accepted during contest but scores? During contest end scores of problems were different, during systests it is different, and I guess after systests it will be different.

GlebsHP I understand validator can be wrong but what's with this Score issue?

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Dynamic Scoring. The score of each problem will decrease according to the amount of accepted solutions (pretest passed) it gets.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    It's called dynamic scoring. The maximum score of a problem is a function of the number of participants who correctly solved it. The higher the number of participants solving the question, the lower the score.

    • »
      »
      »
      9 лет назад, # ^ |
      Rev. 3   Проголосовать: нравится +19 Проголосовать: не нравится

      Still he is right about situation at the beginning of the contest — for a first few minutes two problems in the middle of the problemset (probably E and F, but I'm not sure) had score equal to 500, while other tasks had 3000.

      P.S. And also I wasn't able to see list of contestants in my room for a few minutes at the beginning — it was simply displayed as empty :)

      • »
        »
        »
        »
        9 лет назад, # ^ |
        Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

        I was just one of the problem setters. I didn't handle the server side of things. Maybe GlebsHP can answer to you regarding this.

    • »
      »
      »
      9 лет назад, # ^ |
      Rev. 4   Проголосовать: нравится -8 Проголосовать: не нравится

      mkrjn99 I am aware of dynamic scoring** of codeforces which decreases as times passes. But Full Score doesn't decreases or changes right?

      **Aware of fact that maximum achievable score by a user will decrease as time passes!

»
9 лет назад, # |
  Проголосовать: нравится +7 Проголосовать: не нравится

Why and how every time the score of the problems in contest was changing?

I noticed :

  1. When contest started score of Problem E was 250, so I started doing that.

  2. Then after a refresh, score of Problem A 750 and E was still 250.

  3. Then A became of 500 then it became of 250 now at the time of systests it is of 500!

  4. Score of other problems also changed.

Is this legit during contest?

Wrong validator/test cases can be accepted during contest but scores? During contest end scores of problems were different, during systests it is different, and I guess after systests it will be different.

GlebsHP I understand validator can be wrong but what's with this Score issue?

»
9 лет назад, # |
  Проголосовать: нравится -7 Проголосовать: не нравится

why is the system test totally stuck and the site are dying ?

»
9 лет назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Codeforces back, System testing completed :D Backtracking optimized solutions passes for C: http://mirror.codeforces.com/contest/633/submission/16361771

Failed on D but ranking shifted just by 10, lot of fails on C/D

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

why this submission gets failed ?!?!?! 16362350

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

The points for the 3rd question, right at the end of the contest, was maximum 1000. I guess by then all scores had to be static. However, at the end of sys-tests, the scores for C has gone to 1500.

I am not sure if this fair, and as per rules, scores should depend on number of pretests passed, so why did they change post systests?

GlebsHP — can you please check?

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Check it hereAssign the value of the task dynamically depending on the number who have solved this problem. During the main contest time here will be taken into account the submissions with verdict "Pretests passed", but after system test — "Accepted".

    So it is perfectly fine if points for some problem will increase after a system testing (because of people passing pretests but failing final testing).

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      Had no idea about this. I have never seen this till now to be honest. This was an experiment it seems. Did it stick?

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится 0 Проголосовать: не нравится

        This is not an experiment. I have seen this before in another contest also. Please check link: http://mirror.codeforces.com/contest/550

        • »
          »
          »
          »
          »
          9 лет назад, # ^ |
            Проголосовать: нравится 0 Проголосовать: не нравится

          That link doesn't really help as there is no way to know whether the scores were processed due to number of pretests passed or systests passed. It could well be that A had fewer pretests passing, hence the scores were low. Not saying that you are right or wrong, just that the example makes no sense.

          More importantly, why weren't any announcements made before the contest about the dynamic scoring? This seems to be a rare event, and it would have been fair if everybody knew the rules. In every other contest, the scoring distribution is mentioned just before the contest starts.

          • »
            »
            »
            »
            »
            »
            9 лет назад, # ^ |
              Проголосовать: нравится 0 Проголосовать: не нравится

            I participated in the contest myself and that's how I remember that the scoring was decided on the basis of system tests and not pretests.

            Regarding the announcement about the scoring, yes I agree, this was a mistake from our side.

»
9 лет назад, # |
  Проголосовать: нравится -6 Проголосовать: не нравится

Really strict and annoying final tests for C and D :(

»
9 лет назад, # |
  Проголосовать: нравится +1 Проголосовать: не нравится

After the contest, I'm sure that my solution for D will be judged WA, but in the end, my ABC is WA while D is AC. I'm sure it will fail at a test has 500 0's and 500 1's, but there's no such test in the final test.

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Any editorial? No? Why? Oh, OK....![ ]( )

»
9 лет назад, # |
  Проголосовать: нравится +5 Проголосовать: не нравится

Where is an editorial?

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

hello why my problem is Skipped in the cantest Manthan, Codefest 16??

......................

»
9 лет назад, # |
  Проголосовать: нравится +9 Проголосовать: не нравится

Gaddammit. I failed E and lost 80 places because of an uncommented debug output.

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    Very sad indeed!

  • »
    »
    9 лет назад, # ^ |
      Проголосовать: нравится +5 Проголосовать: не нравится

    Use cerr

    • »
      »
      »
      9 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится

      I use vigilance and check such things everytime (to me, programming is more like self-programming). I missed it this time... but it's quite surprising that it wasn't caught by pretests.

      • »
        »
        »
        »
        9 лет назад, # ^ |
          Проголосовать: нравится +14 Проголосовать: не нравится

        There are more advantages to cerr other than the fact that it's a different stream than cout, e.g. the fact that cerr output isn't buffered — if you print debug info using cout and your program crashes the buffered output might not get printed, but with cerr this is never the case.

        • »
          »
          »
          »
          »
          9 лет назад, # ^ |
          Rev. 2   Проголосовать: нравится +8 Проголосовать: не нравится

          That's why I use endl with debug outputs. Further vigilance.

          It's not a good approach to programming — I'm aware, but that's not why I do it.

»
9 лет назад, # |
Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

TLE in D in 99 testcase!

Is std::map that slow ??

using std::unordered_map gives TLE on 69 testcase ..

Are there some other alternatives of using hash in c++?

»
9 лет назад, # |
  Проголосовать: нравится +39 Проголосовать: не нравится

Can someone answer on this questions, please:

  1. Why ML in E is so strict?

  2. Why this solution (16364814) get ML on Java 8 and get AC on Java 7?

  3. Does 32-bit Java version exist on Codeforces?

»
9 лет назад, # |
  Проголосовать: нравится +11 Проголосовать: не нравится

My solution for A problem (http://mirror.codeforces.com/contest/633/submission/16362922) was hacked during the contest and the same solution is now accepted when i submitted it again (http://mirror.codeforces.com/contest/633/submission/16377008).

Infact the test case on which i was hacked is not itself valid.(1 1 100000) since range of cwas less than 10000.

HOW IS THIS POSSIBLE??

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Interesting, the editorial got hidden... You need to click this to see it — http://mirror.codeforces.com/blog/entry/43392 :) Well, it wasn't very pithy so it's not a big deal.

»
9 лет назад, # |
  Проголосовать: нравится +6 Проголосовать: не нравится

It was bad and buggy night for me :-(

»
9 лет назад, # |
  Проголосовать: нравится +29 Проголосовать: не нравится

Somehow upsolved C with regex'es (built-in backtracking), 1.1 sec. Perl — 16382698

»
9 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Why my submission gets wrong answer in problem C ?!?!?! 16369028