File tree 1 file changed +3
-3
lines changed
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -12,7 +12,7 @@ def __init__(self):
12
12
self .nodes = dict () # Mapping from char to TrieNode
13
13
self .is_leaf = False
14
14
15
- def insert_many (self , words : [str ]):
15
+ def insert_many (self , words : [str ]): # noqa: F821 This syntax is Python 3 only
16
16
"""
17
17
Inserts a list of words into the Trie
18
18
:param words: list of string words
@@ -34,7 +34,7 @@ def insert(self, word: str): # noqa: F821 This syntax is Python 3 only
34
34
curr = curr .nodes [char ]
35
35
curr .is_leaf = True
36
36
37
- def find (self , word : str ) -> bool :
37
+ def find (self , word : str ) -> bool : # noqa: F821 This syntax is Python 3 only
38
38
"""
39
39
Tries to find word in a Trie
40
40
:param word: word to look for
@@ -48,7 +48,7 @@ def find(self, word: str) -> bool:
48
48
return curr .is_leaf
49
49
50
50
51
- def print_words (node : TrieNode , word : str ):
51
+ def print_words (node : TrieNode , word : str ): # noqa: F821 This syntax is Python 3 only
52
52
"""
53
53
Prints all the words in a Trie
54
54
:param node: root node of Trie
You can’t perform that action at this time.
0 commit comments