Problem is
\"You are climbing a stair case. Each time you can either make 1 step or 2 steps. The staircase has n steps. In how many distinct ways can you climb the s
Climbing Stairs Using DP
class Solution { public: int climbStairs(int n) { int dp[n+1]; if (n <= 1) return 1; if (n ==2) return 2; dp[0] = 1; dp[1] = 1; dp[2] = 2; for (int i = 3; i <=n; i++){ dp[i] = dp[i-1]+dp[i-2]; } return dp[n]; }};