Text Search: search a word, then search a phrase (follow-up)
Coding: Text Search (word search, then phrase search follow-up)
Given a multi-line text, support two query types:
- Query a word
word: return how many times it appears in the text (token-ba...
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Standard Input
Execution Result:
