Question: Please provide the answers in this way Problem -> Ideas -> Mathematical formulation -> Mathematical analysis -> Plain English algorithm -> Pseudocode -> Code If

Please provide the answers in this way

Problem -> Ideas -> Mathematical formulation -> Mathematical analysis -> Plain English algorithm -> Pseudocode -> Code

If you write code please do it in java and provide a detailed explanation of the answer and the complexity. The explanation is the most important aspect

1. Consider the following pseudocode for finding the length of the longest common subsequence function LLCS(i, j;; A, B, Look) if Look[i, j] not nil then return Look[i, j] end if if i == 0 or j == 0 then Look[i, j] 0 else if A[i] == B[j] then Look[i, j] 1 + LLCS(i, j, A, B, Look) else Look[i, j] max(LLCS(i - 1, j, A, B, Look), LLCS(i, j - 1, A, B, Look)) end if end if return Look[i, j] end function function LLCSW(A, B) Look[0..length(A), 0..length(B)] initialized with nil return LLCS(length(A), length(B), A, B, Look) end functionPlease provide the answers in this way Problem -> Ideas -> Mathematical

1. Consider the following pseudocode for finding the length of the longest common subsequence function LLCS(L, j; A, B, Look) if Looki, j] not nil then return Look|i, j] end if if i else 0 or J-0 then Lookli, j] 0 if Ali| = Blil then Looki, j] 1 + LLCS(i, j, A, B, Look) else Looki, j] max(LLCS(i- 1, j, A, B, Look), LLCS(i, j - 1, A, B, Look)) end if end if return Look[i, j] end function function LLCSW(A, B) Look[0..length(A), 0..length(B)] initialized with nil return LLCS (length(A), length(B), A, B, Look) end function Find the values in the look-up table Look by the end of the call LLCSW("aabb", "abab")

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!