Write a program pronounce.cpp that
-
Lets the user input a word (let’s call the input wordW).
-
If the word is not found in the dictionary, print “Notfound”. Otherwise, report:
- Pronunciation : the pronunciation of the word W (asgiven in the dictionary),
- Identical : other words from the dictionary with thesame pronunciation as W,
- Replace phoneme : words that can be obtained from W byreplacing one phoneme.
- Add phoneme : words that can be obtained from W byadding one phoneme,
- Remove phoneme : words that can be obtained from W byremoving one phoneme,
When listing words, include all words from thedictionary that meet the criteria, the order of listed wordsshould be the same as they appear in the dictionary.
Your program should expect that the dictionary file cmudict.0.7ais located in the current working directory.
User input should be case-insensitive (accepting donut, DONUT,DOnUt, etc.)
Please, don’t make complex user interface that allows multiplequeries.
I NEED HELP WITH THE REMOVE PHONEME PART
Expert Answer
Answer to Write a program pronounce.cpp that Lets the user input a word (let’s call the input word W). If the word is not found …