krish2004's blog

By krish2004, history, 4 months ago, In English

https://mirror.codeforces.com/contest/1985/problem/H1. For this problem when I am running the same code on VS code it is coming correct but when I am submitting it is showing garbage value. 271078629

Full text and comments »

Tags dsu
  • Vote: I like it
  • -3
  • Vote: I do not like it

By krish2004, history, 5 months ago, In English

How to approach problems for DP? and as a beginner should I start approaching the question in tabulation method or in recursive method and then change it to the tabulation method ?

Full text and comments »

Tags dp
  • Vote: I like it
  • -24
  • Vote: I do not like it

By krish2004, history, 5 months ago, In English

https://mirror.codeforces.com/contest/1983/problem/D

In this problem. Count inversion concept comes into play but why ?? What is the exact intuition behind it? Like why only count inversion. and what are the other type of problems where this concept is used.

Full text and comments »

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

By krish2004, history, 5 months ago, In English

I cant understand why https://mirror.codeforces.com/contest/1987/submission/268352950 is not giving TLE but this is https://mirror.codeforces.com/contest/1987/submission/268340248. Both have same approach for the same question.

Full text and comments »

Tags tle, dp
  • Vote: I like it
  • 0
  • Vote: I do not like it