link------------>
please kindly tell me.
link------------>
please kindly tell me.
@swapnoneelmajumdar this should be done by 3D DP!
consider this test case:
abcd
bacd
acbd
answer should be 3(acd) but your code gives 2.
This is because if you carefully observe, then for s1 and s2, LCS are acd or bcd.
But for s3 you only consider bcd!
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.