MCPcopy Create free account
hub / github.com/TheAlgorithms/Go / getLCSTestCases

Function getLCSTestCases

dynamic/longestcommonsubsequence_test.go:15–34  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

13}
14
15func getLCSTestCases() []testCaseLCS {
16 return []testCaseLCS{
17 {"ABCDGH", "AEDFHR", 3},
18 {"AGGTAB", "GXTXAYB", 4},
19 {"programming", "gaming", 6},
20 {"physics", "smartphone", 2},
21 {"computer", "food", 1},
22 {"123", "12345", 3},
23 {"XYZ", "XYZ", 3},
24 {"XYZ", "XYZa", 3},
25 {"XYZ", "aXYZ", 3},
26 {"0123", "abc", 0},
27 {"abcdef", "aXbXcXXXdeXXf", 6},
28 {"", "abc", 0},
29 {"", "", 0},
30 {"££", "££", 2},
31 {"x笑x笑", "aaa笑a笑", 2},
32 {"xYxY", "aaaYaY", 2},
33 }
34}
35
36func TestLongestCommonSubsequence(t *testing.T) {
37 t.Run("Simple test", func(t *testing.T) {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected