Question: Write a python program that reads from a file called abreviations.txt, a set of abbreviations as shown in Figure.1 and constructs an adequate dictionary for
Write a python program that reads from a file called abreviations.txt, a set of abbreviations as shown in Figure.1 and constructs an adequate dictionary for storing them. Your program will then ask the user to enter the name of a file, reads the contents of the file and replace any occurrences of the words on the right of the abbreviation with those on its left. For example, the world fortunate becomes 4tun8.
8:ate 2:too 2:to 4:for a:at &:and Figure. 1: Sample contents of abbreviations.txt
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
