feat(content): function signatures + test cases
This commit is contained in:
@@ -9,6 +9,26 @@ categories:
|
||||
patterns:
|
||||
- two-pointers
|
||||
|
||||
function_signature: "def array_strings_are_equal(word1: list[str], word2: list[str]) -> bool:"
|
||||
|
||||
test_cases:
|
||||
visible:
|
||||
- input: { word1: ["ab", "c"], word2: ["a", "bc"] }
|
||||
expected: true
|
||||
- input: { word1: ["a", "cb"], word2: ["ab", "c"] }
|
||||
expected: false
|
||||
- input: { word1: ["abc", "d", "defg"], word2: ["abcddefg"] }
|
||||
expected: true
|
||||
hidden:
|
||||
- input: { word1: ["a"], word2: ["a"] }
|
||||
expected: true
|
||||
- input: { word1: ["a", "b", "c"], word2: ["abc"] }
|
||||
expected: true
|
||||
- input: { word1: ["ab"], word2: ["a", "b"] }
|
||||
expected: true
|
||||
- input: { word1: ["abc"], word2: ["ab"] }
|
||||
expected: false
|
||||
|
||||
description: |
|
||||
Given two string arrays `word1` and `word2`, return `true` *if the two arrays **represent** the same string, and* `false` *otherwise*.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user