Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A charity is having a silent auction where people place bids on a prize without knowing anyone elses bid. Each bid includes a persons name

A charity is having a silent auction where people place bids on a prize without knowing anyone elses bid. Each bid includes a persons name and the amount of their bid. After the silent auction is over, the winner is the person who has placed the highest bid. If there is a tie, the person whose bid was placed first wins. Your job is to determine the winner of the silent auction. Input Specification The first line of input contains a positive integer N, where 1 N 100, representing the number of bids collected at the silent auction. Each of the next N pairs of lines contains a persons name on one line, and the amount of their bid, in dollars, on the next line. Each bid is a positive integer less than 2000. The order of the input is the order in which bids were placed. Output Specification Output the name of the person who has won the silent auction.

Java Language

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Data Management Databases And Organizations

Authors: Watson Watson

5th Edition

0471715360, 978-0471715368

More Books

Students also viewed these Databases questions

Question

Provide examples of Dimensional Tables.

Answered: 1 week ago