Answer to Question #274782 in Python for bubu

Question #274782

Assume, you have been given a tuple with details about books that won the Good Reads Choice Awards.

book_info = (

("Best Mystery & Thriller","The Silent Patient",68821),

("Best Horror","The Institute",75717),

("Best History & Biography","The five",31783 ),

("Best Fiction","The Testaments",98291)

)

Write a Python program that prints the award category, the book name, and its total votes earned as shown below.



1
Expert's answer
2021-12-02T14:15:43-0500
book_info = (
	("Best Mystery & Thriller","The Silent Patient",68821),
	("Best Horror","The Institute",75717),
	("Best History & Biography","The five",31783),
	("Best Fiction","The Testaments",98291))
for book in book_info:
	print(f"{book[1]} won the '{book[0]}' category with {book[2]} votes")

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be the first!

Leave a comment

LATEST TUTORIALS
New on Blog
APPROVED BY CLIENTS