Question: ANSWER NEEDED IN PYTHON THINK, PAIR, SHARE #2 - BUILD A DICTIONARY TO STORE FREQUENCY DATA Write a program that categorizes each mail message by

ANSWER NEEDED IN PYTHON ANSWER NEEDED IN PYTHON THINK, PAIR, SHARE \#2 - BUILD A

THINK, PAIR, SHARE \#2 - BUILD A DICTIONARY TO STORE FREQUENCY DATA Write a program that categorizes each mail message by which day of the week the commit was done. To do this, look for lines that start with "From". Then, look for the third word, and keep a running count of each of the days of the week. At the end of the program, print out the contents of the dictionary mail count (order does not matter). For example, mail count['Mon'] should be 2. Use the following list as your data: mail = ['From lacher@uhcl.edu Sat Jan 7', 'From gopal.ramasammycook@gmail.com Thurs Jan 5', 'From louis@media.berkeley.edu Tues Jan 3', 'From antranig@uhcl.edu Sat Jan 7', 'From david.horwitz@yahoo.com Wed Jan 4', 'From ray@media.berkeley.edu Mon Jan 2', 'From lacher@uhcl.edu Mon Jan 2', 'From wagnermr@uh.edu Fri Jan 6']

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!