Question: Write a program that asks a user to type in two strings and that prints 1. the characters that occur in both strings. 2. the
Write a program that asks a user to type in two strings and that prints 1. the characters that occur in both strings. 2. the characters that occur in one string but not the other. 3. the letters that don't occur in either string. Use the set function to turn a string into a set of characters. PYTHON Books and Authors A book could be written by a single author or multiple authors. Write a program to read the books and authors in the books.txt file and put them in a dictionary. Output the books organized by author. Name the source code file "books.py" Your program should behave as follows: Carroll ["Alice's Adventures in Wonderland "] Twain ['Adventures of Huckleberry Finn', 'Tom Sawyer'] Austen ['Pride and Prejudice '] Benedict ['How to Analyze People on Sight '1 Vatsyayana ['The Kama Sutra of Vatsyayana'] Johnson ['The Song My Paddle Sings'] Sunzi ['The Art of War '] Bronte ['Jane Eyre '1 Doyle ['The Adventures of Sherlock Holmes '1 books.txt The Kama Sutra of Vatsyayana, Vatsyayana The Song My Paddle Sings, E. Pauline Johnson Adventures of Huckleberry Finn, Mark Twain The Adventures of Sherlock Holmes Sir Arthur Conan Doyle Pride and Prejudice , Jane Austen How to Analyze People on Sight, Elsie Lincoln Benedict Alice's Adventures in Wonderland, Lewis Carroll The Art of War, Sunzi Jane Eyre Charlotte Bronte Tom Sawyer, Mark Twain
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
