Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
|
|
@ -0,0 +1,12 @@
|
|||
function LCS(a, b)
|
||||
if length(a) = 0 or length(b) = 0 then return ""
|
||||
while length(b)
|
||||
for j = length(b) to 1 step -1
|
||||
if instr(a, left(b, j)) then return left(b, j)
|
||||
next j
|
||||
b = mid$(b, 2)
|
||||
end while
|
||||
end function
|
||||
|
||||
print LCS("thisisatest", "testing123testing")
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue