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

Автор kostya_by, 9 лет назад, По-русски

Hello CodeForces Community,

I would like to co-ordially invite you all to take part in the CodeChef April Cook-Off. The problems were set by me and tested by shef_2318 (Pavel Sheftelevich). I hope you will enjoy solving them. Please give me your feedback on the problem set in the comments below after the contest. Please find the rest of the details about the contest below.

Time: 17th April 2016 (2130 hrs) to 18th April 2016 (0000 hrs). (Indian Standard Time — +5:30 GMT) — Check your timezone.

Details: https://www.codechef.com/COOK69

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.

  • Problem Setter: kostya_by (Kanstantsin Sokal)
  • Problem Tester & Russian Translator: shef_2318 (Pavel Sheftelevich)
  • Mandarin Translator: huzecong (Hu Zecong)
  • Contest Admin & Editorialist: PraveenDhinwa (Praveen Dhinwa)
  • Vietnamese Translator: VNOI Team

Prizes:

  • Top 10 performers in Global and Indian category will get CodeChef laddus, with which the winners can claim cool CodeChef goodies. Know more here: https://www.codechef.com/laddu. (For those who have not yet got their previous winning, please send an email to winners@codechef.com)

Good Luck! Hope to see you participating!

UPD

The contest starts in 30 minutes!

Good luck everyone!

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

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

Maybe this is a dumb question, but I see that most of the AC solutions for BITTWIST sort the adjacency lists of each vertex. Is there some reason for this? Shouldn't they already be added in sorted order?

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

How to solve the last problem?

BTW, problem D is very similar to this problem

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

    Seems like O(K) per query with memoization amortizes the complexity of the solution to O(N root N). Can someone prove this?