Write a Python program that finds the largest value with its key from a given dictionary. [You are not allowed to use the max() function for this task] Note: You do not need to take the dictionaries as an input from the user but your code should work for any given dictionary. Also, you need to handle the quotation marks as a part of the output. Hint: Think of membership operators (in and not in). You can use dictionary functions to get the values. ================: ======================= =================-
Write a Python program that finds the largest value with its key from a given dictionary. [You are not allowed to use the max() function for this task] Note: You do not need to take the dictionaries as an input from the user but your code should work for any given dictionary. Also, you need to handle the quotation marks as a part of the output. Hint: Think of membership operators (in and not in). You can use dictionary functions to get the values. ================: ======================= =================-
Chapter3: Data Representation
Section: Chapter Questions
Problem 12VE
Related questions
Question
Must show it in Python:
Please show step by step with comments.
Please show it in simplest form.
Please don't use any functions
Please don't use any def func ()
Input and Output must match with the Question
Please go through the Question very carefully.
![Task 10
Write a Python program that finds the largest value with its key from a given dictionary.
[You are not allowed to use the max() function for this task]
Note: You do not need to take the dictionaries as an input from the user but your code should work for any given dictionary. Also, you need to handle the
quotation marks as a part of the output.
Hint: Think of membership operators (in and not in). You can use dictionary functions to get the values.
====== ===
3====
Sample 1:
Given:
{'sci fi': 12, 'mystery': 15, 'horror': 8, 'mythology': 10, 'young_adult': 4, 'adventure':14}
Output:
The highest selling book genre is 'mystery' and the number of books sold are 15.
=====
!===== ===== ===
Sample 2:
Given:
{'sci fi': 5, 'mystery': 3, 'horror': 14, 'young_adult': 2, 'adventure':9}
Output:
The highest selling book genre is 'horror' and the number of books sold are 14.
===== ====-===
===============================](/v2/_next/image?url=https%3A%2F%2Fcontent.bartleby.com%2Fqna-images%2Fquestion%2Fce0060ff-4d7e-4125-a5ff-63ad9cd04436%2Ff0826339-b896-4b44-b779-2503b016ae2d%2F10hymuo_processed.png&w=3840&q=75)
Transcribed Image Text:Task 10
Write a Python program that finds the largest value with its key from a given dictionary.
[You are not allowed to use the max() function for this task]
Note: You do not need to take the dictionaries as an input from the user but your code should work for any given dictionary. Also, you need to handle the
quotation marks as a part of the output.
Hint: Think of membership operators (in and not in). You can use dictionary functions to get the values.
====== ===
3====
Sample 1:
Given:
{'sci fi': 12, 'mystery': 15, 'horror': 8, 'mythology': 10, 'young_adult': 4, 'adventure':14}
Output:
The highest selling book genre is 'mystery' and the number of books sold are 15.
=====
!===== ===== ===
Sample 2:
Given:
{'sci fi': 5, 'mystery': 3, 'horror': 14, 'young_adult': 2, 'adventure':9}
Output:
The highest selling book genre is 'horror' and the number of books sold are 14.
===== ====-===
===============================
Expert Solution
![](/static/compass_v2/shared-icons/check-mark.png)
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
This is a popular solution!
Trending now
This is a popular solution!
Step by step
Solved in 3 steps with 1 images
![Blurred answer](/static/compass_v2/solution-images/blurred-answer.jpg)
Knowledge Booster
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.Recommended textbooks for you
![Systems Architecture](https://www.bartleby.com/isbn_cover_images/9781305080195/9781305080195_smallCoverImage.gif)
Systems Architecture
Computer Science
ISBN:
9781305080195
Author:
Stephen D. Burd
Publisher:
Cengage Learning
![Systems Architecture](https://www.bartleby.com/isbn_cover_images/9781305080195/9781305080195_smallCoverImage.gif)
Systems Architecture
Computer Science
ISBN:
9781305080195
Author:
Stephen D. Burd
Publisher:
Cengage Learning