Doubt in optimazation

I am solving this question from leetcode…
This is the question…
392. Is Subsequence

This is my solution(Top Down).


I want to know can i optimize this top down approch further…

Hey @ashishnnnnn
There can be 2 case if char equal move i+1,j+1
And if not equal move i,j+1

U are making one extra recursive call of i+1,j in 2nd case
Remove that
Rest looks good and I can’t think that it can be optimized further
I optimized dp array space here

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.