()
| 1 | // Time O (ws + nm*8^s) | Space O(nm + ws) |
| 2 | class Trie { |
| 3 | constructor() { |
| 4 | this.root = {}; |
| 5 | this.endSymbol = "*"; |
| 6 | } |
| 7 | add(string) { |
| 8 | let currentNode = this.root; |
| 9 | for (const char of string) { |
nothing calls this directly
no outgoing calls
no test coverage detected