All problems

The Record Day

easyPythonTime SeriesLists

At the end of a run Meridian's owner writes the record day on the board. Not the number of cups — everyone behind the counter already remembers that — but which day of the run it was, so the staff can argue about what made it happen. The team count days from one, the way people do, starting with the first day of the run. Two days landing on the same count is common enough that the shop has a house rule for it: the day that got there first holds the record, and a later day has to beat it rather than match it.

Task: Print which day set the record.

Input

The first line holds an integer n, the number of days. Each of the next n lines holds one day's cup count. Counts may repeat, including at the very top of the run.

Output

One line: the word day, one space, then the day's number counting from 1, so the opening day of the run is day 1. If the highest count was reached on more than one day, the earliest of those days is the one that goes on the board.

Example:

Input:
3
5
9
3

Output:
day 2

Sign in to solve this problem

Reading problems is free for everyone — solving them (Run, Submit, and tracking what you've solved) needs an account.

Sign in

Discussion

Sign in to join the discussion — reading is open to everyone.

Loading comments…