cho.sh
NotesCho Mini
Loading...

Maximum Value

Time limit

1s

Memory limit

128 MB

Problem

You are given 81 numbers written in a 9 by 9 grid. Each number is either a natural number or 0. Find the largest number, then determine the row and column where that number is located. Row and column numbers start from 1.

Input

Nine lines are given. Each line contains nine integers separated by spaces. Every number is at least 0 and less than 100.

Output

Print the largest number on the first line. On the second line, print the row number and column number of that value, separated by a space. If the largest number appears in more than one cell, you may print any one of its positions.