MCPcopy Create free account
hub / github.com/Seogeurim/CS-study / main

Method main

contents/data-structure/code/Trie/TrieExample.java:5–21  ·  view source on GitHub ↗
(String[] args)

Source from the content-addressed store, hash-verified

3public class TrieExample {
4
5 public static void main(String[] args) {
6 Trie t = new Trie();
7
8 /* insert words */
9 t.insert("a");
10 t.insert("inn");
11 t.insert("to");
12 t.insert("tea");
13 t.insert("ted");
14 t.insert("ten");
15
16 /* search words */
17 System.out.println(t.checkWord("inn"));
18 System.out.println(t.checkWord("tea"));
19 System.out.println(t.checkWord("tee"));
20 System.out.println(t.checkWord("te"));
21 }
22}
23
24class Trie {

Callers

nothing calls this directly

Calls 2

insertMethod · 0.95
checkWordMethod · 0.95

Tested by

no test coverage detected