Can anyone please explain how this problem can be solved in top-down manner (Recursive dp).
# | User | Rating |
---|---|---|
1 | jiangly | 3846 |
2 | tourist | 3799 |
3 | orzdevinwang | 3706 |
4 | jqdai0815 | 3682 |
5 | ksun48 | 3590 |
6 | Ormlis | 3533 |
7 | Benq | 3468 |
8 | Radewoosh | 3463 |
9 | ecnerwala | 3451 |
9 | Um_nik | 3451 |
# | User | Contrib. |
---|---|---|
1 | cry | 165 |
2 | -is-this-fft- | 161 |
3 | Qingyu | 160 |
4 | Dominater069 | 158 |
5 | atcoder_official | 157 |
6 | adamant | 154 |
7 | Um_nik | 151 |
8 | djm03178 | 150 |
9 | luogu_official | 149 |
10 | awoo | 147 |
Can anyone please explain how this problem can be solved in top-down manner (Recursive dp).
Is there any way to space optimize a recursive DP for example say the 0-1 knapsack problem where we can do it iteratively using a 2xN dp array iteratively. Recently I came across this probelem and this problem where I was forced to use an iterative DP. Is there any way to solve these problems recursively?
I am stuck in this problem, I and not able to identify why I am getting a TLE. My submission and the Problem Link
Name |
---|