Got the logic but thinking about time complexity is it O(N*2^N) and space ??
What is the time complexity and space complexity
no , time compxity and space complexity is number of characters in the keypad,
example 12 gives ae, af, ag, be, bf, bg, so number of characters in “1” are 3 and number of characters in “2” are 3. Therefore 3*3 tital characters, you can check that when stack builds up
I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.
On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.