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

Автор RomaWhite, история, 5 лет назад, По-английски

Greetings Codeforces Community!

CodeChef presents July Lunchtime contest! The 3-hour long contest is jam-packed with engrossing problems that is sure to be an absolute treat for you. So, get ready to code and compete!

Further, if you have some engaging problem ideas and want them to be used in CodeChef's contests, you can share them with our admins here: www.codechef.com/problemsetting/new-ideas

Expecting to see you join your fellow coders and participate in the contest in large numbers. Joining me on the problem setting panel are:

  • Setters: kingofnumbers (Hasan Jaddouh), Erfan.aa (Erfan Alimohammadi)
  • Tester: RomaWhite (Roman Bilyi)
  • Editorialist: vijju123 (Abhishek Pandey)
  • Statement Verifier: Xellos (Jakub Safin)
  • Mandarin Translator: gediiiiiii (Gedi Zheng)
  • Vietnamese Translator: Team VNOI
  • Russian Translator: Mediocrity (Fedor Korobeinikov)
  • Bengali Translator: solaimanope (Mohammad Solaiman)
  • Hindi Translator: Akash Shrivastava

    Contest Details:

  • Start Date & Time: 27th July 2019 (1930 hrs) to 27th July 2019 (2230 hrs). (Indian Standard Time — +5:30 GMT) — Check your timezone
  • Contest link: https://www.codechef.com/LTIME74
  • Registration: You just need to have a CodeChef handle to participate. For all those, who are interested and do not have a CodeChef handle, are requested to register in order to participate.
  • Prizes: Top 10 Indian and top 10 Global school students from ranklist will receive certificates and CodeChef laddus, with which the winners can claim cool CodeChef goodies. Know more here: https://discuss.codechef.com/t/how-do-i-win-a-codechef-goodie/7344. (For those who have not yet got their previous winning, please send an email to [email protected]) Good Luck!
    Hope to see you participating!!
    Happy Programming!!
  • Проголосовать: нравится
  • -16
  • Проголосовать: не нравится

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

How to solve PROFTRIP ?

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

    Like usual Dijstjka, but you have to maintain more than one minimum weight. The minimum weight is a pair of (spentMoney, minFuelPrice). So, for every reached city, there can be more than one such pair. Then simply follow all cheapest paths until target is found.

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

      Thanks. Btw, due to smaller constraints, I'm finding many codes with floyd — warshall too.

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

        I think the Floyed-Warshal finds all possible, paths. Then you can calc the price for every one, and use the smallest price. Not sure wich solution is better.

        Edit: How do you know when to stop the loop with Floyd-Warshal? You need to run it for countNode times. That should TLE for special test cases.

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

    If we want to go to another state we would always want to buy fuel from the state we've passed so far that has the minimum fuel price. So we add another dimension to our search state to include the index of the city with the minimum fuel price so far and we do Dijkstra on that.

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

In equal median, what should be the answer for the following testcase:

1

5 1

1 1 2 2 3

1 1

Some accepted solutions gives 2. However imo it should be 1.

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

    Same question here... all four accepted solutions print 2 but I can't see how it's not 1.

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

Either the test cases for EQMD are completely incorrect or I have misunderstood the problem. The following code got 50 points by just outputting the frequency of the median element. That would fail on so many cases. https://www.codechef.com/viewsolution/25455347

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

The test-cases of EQMD turned out to be wrong, hence the contest is unrated for div1 participants, we still didn't decide for div2.

I'm very sorry for this mistake.

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

    Will it be possible to submit it later with correct test cases? it was an interesting problem

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

    It happens to the best of us ;)

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

    I asked you. But you gave me wrong answer -.-

    tmp

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

      can you please share your approach?

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

      The correct answer to such a useless question (do you seriously expect someone to assume they made wrong tests?) is "no comment", be glad you didn't get that.

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

        I was not expecting any answer there.
        That was written in frustration after making odd 10 submissions and seeing low success rate despite easy 50pts?

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

      I resubmitted a correct answer to your question before the contest ends, do I get the score of the question ?

      seriously speaking, we didn't suspect of any issues in EQMD until very late, that was mainly because it's sometimes normal for 4th problem to have low number of solvers until the last 30 minutes of the contest, another reason was the problem TWOLANE which had less solvers than two other problem despite it's very straight forward greedy problem! this was weird enough to make me think high number of WA on EQMD isn't that weird. I apologize again for this mistake from us!

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

    Will the top students get laddus?

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

    Please make div 2 rated.

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

All submissions of EQMD are rejudged.

The contest is unrated for div1, while it's still rated for div2.

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

    This is the reason we get frustrated. Spend 3 and 1/2 hours and in return get an unrated round. Thanks.