Search if a word is present in the trie.

trie_contain(trie, word)

Arguments

trie

A trie.

word

The word to be searched in the trie.

Value

a logical indicating that if the word is present or not. Returns TRUE if the word is in the trie. Returns FALSE if the word is not in the trie.

Examples

trie <- trie_create() trie_contain(trie, "test")
#> [1] FALSE