bokuto_alright's blog

By bokuto_alright, 7 weeks ago, In English

Question here: https://www.codechef.com/practice/course/4-star-difficulty-problems/DIFF1900/problems/ICL1901?tab=statement

1st submission with just while True: https://www.codechef.com/viewsolution/1055683164

2nd submission running the same code just twice: https://www.codechef.com/viewsolution/1055683982

Why is it so that all combinations are exhausted in only 2 iterations?

Extra doubt:

Why and how does this solution work?: https://www.codechef.com/viewsolution/89676081

Full text and comments »

  • Vote: I like it
  • 0
  • Vote: I do not like it

By bokuto_alright, history, 2 months ago, In English

Question here: https://www.codechef.com/practice/course/4-star-difficulty-problems/DIFF1900/problems/SEGDIV?tab=statement

I'm intrigued about this submission over here: https://www.codechef.com/viewsolution/82916450

I have no idea why it works. The poster also just left out the proof part and simply wrote, "It's difficult to prove it". Is there any proof of this or is just conveniently satisfies for the given question's constraints? (n <= 500)

Full text and comments »

  • Vote: I like it
  • +3
  • Vote: I do not like it