Skip to content

Commit d4c5f09

Browse files
Update dynamic_programming/word_break.py
Co-authored-by: Christian Clauss <[email protected]>
1 parent ab64273 commit d4c5f09

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Diff for: dynamic_programming/word_break.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ def word_break(string: str, words: list[str]) -> bool:
6161
if not isinstance(word_dict, list) or not all(
6262
isinstance(item, str) and len(item) > 0 for item in word_dict
6363
):
64-
raise ValueError("the word_dict should a list of non empty string")
64+
raise ValueError("the words should be a list of non-empty strings")
6565

6666
# Build trie
6767
trie: dict[str, Any] = {}

0 commit comments

Comments
 (0)