06. Count ways to N'th Stair
My Approach
Time and Auxiliary Space Complexity
Code (C++)
class Solution {
public:
long long countWays(int n) {
return n / 2 + 1;
}
};Contribution and Support
Last updated