Data update

This commit is contained in:
Ingy döt Net 2026-02-01 16:33:20 -08:00
parent 5150844a7d
commit 4bb20c9b71
7735 changed files with 38060 additions and 199180 deletions

View file

@ -2,25 +2,16 @@ func$ right a$ n .
return substr a$ (len a$ - n + 1) n
.
func$ left a$ n .
if n < 0
n = len a$ + n
.
if n < 0 : n = len a$ + n
return substr a$ 1 n
.
func$ lcs a$ b$ .
if len a$ = 0 or len b$ = 0
return ""
.
if right a$ 1 = right b$ 1
return lcs left a$ -1 left b$ -1 & right a$ 1
.
if len a$ = 0 or len b$ = 0 : return ""
if right a$ 1 = right b$ 1 : return lcs left a$ -1 left b$ -1 & right a$ 1
x$ = lcs a$ left b$ -1
y$ = lcs left a$ -1 b$
if len x$ > len y$
return x$
else
return y$
.
if len x$ > len y$ : return x$
return y$
.
print lcs "1234" "1224533324"
print lcs "thisisatest" "testing123testing"