Question
write in Python A file concordance tracks the unique words in a file and their frequencies. Write a program that displays a concordance for a
write in Python
A file concordance tracks the unique words in a file and their frequencies. Write a program that displays a concordance for a file. The program should output the unique words and their frequencies in alphabetical order.
ADDITIONAL REQUIREMENTS:
Your program should allow the user to enter the name of the text file to process for the concordance.
Before you start writing your program, (re)read section 6.2 on Problem Solving with Top-Down Design, because I want you to actually design your program. Split your program up into well-defined functions by doing a top-down design and developing a structure chart.
When you write your program, be sure to use:
meaningful variable names with good style (i.e., useCamelCase or use_underscores)
docstring comments at the start of the program and after the definition of each function which
describing what they do
a main function (see lab4 Part C) located at the top of program with a call to it at the bottom of the file
to start execution
global constants where appropriate with good style (ALL_CAPS_AND_UNDERSCORES).
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started