Quantcast
Channel: CodeChef Discuss - latest questions
Viewing all articles
Browse latest Browse all 39796

What is the best algorithm to find the most occurrence of a word in text?

$
0
0

Does anyone know what is the best algorithm to find the most occurrence of a word in text (very large), so hash map is not a solution I'm looking for. I'm thinking of either "Trie" or "Suffix Array" but I haven't had a clear idea how to solve it. Any idea or suggestion would be greatly appreciated.

For example: This is is is an example.
Then the most occurrence is "is".


Viewing all articles
Browse latest Browse all 39796

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>