Question: Using Python solves the following problem. The input to your program will be a list of votes cast in a city election. Each line will
Using Python solves the following problem. The input to your program will be a list of votes cast in a city election. Each line will contain one the name of a candidate. The end of input will be denoted by ***, which is not to be counted as a vote. If there is a candidate that obtained a simple or absolute majority (i.e., they received more votes than anyone else), display the name of that candidate. If no candidate obtained a simple majority, display "RUNOFF!". You may assume that there is at least one vote and that the input will be entered using the standard input.
Here are some examples of what your program should operate:

Input Output Franklin Roosevelt Franklin Roosevelt Wendell Willkie Franklin Roosevelt Franklin Roosevelt John Doe Wendell Willkie Franklin Roosevelt RUNOFF! Homer Tweety Shaggy Homer Tweety Shaggy Yosemite Shaggy Shaggy Shaggy
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
