Question: Write a program that prompts a user to enter the name of a file and a word. The program should then count all occurrences of
Write a program that prompts a user to enter the name of a file and a word. The program should then count all occurrences of the word in the file and display the number of occurrences. Use a utility program to create a simple text file that has many words in it and that can be used to test the program.
Step by Step Solution
3.45 Rating (152 Votes )
There are 3 Steps involved in it
Heres a Python program that does what youve described python def countwordinfilefilename word Counts ... View full answer
Get step-by-step solutions from verified subject matter experts
