Q10. Greedy10
Complexity of checking whether “hello” can be made after deleting some characters of a given string. Find min Complexity and best Algorithm. Size of hello =5 Size of given String =15
O(5) greedy
O(15) DP
O(5 log 15) geedy
O(15) greedy
Q10. Greedy10
Complexity of checking whether “hello” can be made after deleting some characters of a given string. Find min Complexity and best Algorithm. Size of hello =5 Size of given String =15
O(5) greedy
O(15) DP
O(5 log 15) geedy
O(15) greedy
answer should be O(15) greedy
i don’t think dp solution exist for this
but how is it O(15)?
n=15
and using greedy time complexity is O(n)
so it is O(15)
okay, thank you .
I think dp exist for this. as we have dp for finding supersequence problem we can find for this too.