Skip to content

Commit 03b7600

Browse files
committed
* Renamed method signatures to match formal definitions
1 parent 7cd00a1 commit 03b7600

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

Diff for: data_structures/Trie/Trie.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,12 @@ class TrieNode:
1010
def __init__(self):
1111
self.nodes = dict() # Mapping from char to TrieNode
1212

13-
def add_words(self, words: [str]):
13+
def insert_many(self, words: [str]):
1414
for word in words:
15-
self.add_word(word)
15+
self.insert(word)
1616

17-
def add_word(self, word: str):
17+
def insert(self, word: str):
1818
pass
1919

20-
def lookup_word(self, word: str) -> bool:
20+
def find(self, word: str) -> bool:
2121
pass

0 commit comments

Comments
 (0)