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

Автор ThinkAgain, история, 3 года назад, По-английски

Hello Codeforces Community, Here are the editorials for today's held Google Kickstart Round B 2021. Each and every problem along with their solutions are explained in detail.

Below are the links to the solutions:-

  1. Increasing Substring

  2. Longest Progression

  3. Consecutive Primes

Last problem will be updated soon.

Any suggestions are welcome, do comment in this blog post.

Thank You!!

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

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

Your Explanation for Longest Progression is Awesome. Thanks a lot.

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

thanks for the solutions ^_^

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

in longest progression problem the answer of the second testcase is 6.......................... 5 5 4 5 5 5 4 5 6 -> 5 5 5 5 5 5 4 5 6(by changing the 3rd element) but if the 5th element is changed to 4 then we can get the max length 8................ 5 5 4 5 4 5 4 5 6(by changing the 5th element to 4) from 2nd to last element the difference is 1 and length is 8

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

    We can't get 8 as the maximum possible answer. Note that the definition of arithmetic array says the difference b/w adjacent elements(consider forward-backward). If the question says that we have to consider the absolute value of difference b/w adjacent elements then our answer for this test case would be 8, otherwise, 6 is the correct answer for this TC.