#include <bits/stdc++.h>
using namespace std;

int a[5][5];

int main()
{
	int b,c,d=1,e;
	for(int i=0;i<5;i++)
	{
		for(int j=0;j<5;j++)
		{
			cin>>a[i][j];
		}
	}
	for(int i=0;i<5;i++)
	{
		for(int j=0;j<5;j++)
		{
			if(a[i][j]>b)
			{
				b=a[i][j];
				c=j;
				e=i; 
		    }
		}
		for(int v=0;v<5;v++)
		{	
			if(b>a[v][c])
			{
				d=0;
				break;
			}
		}
	}
	if(d=0)cout<<"not"<<" "<<"found";
	else cout<<e<<' '<<c<<' '<<b;
}

1 comments

  • 1

Information

ID
602
Time
1000ms
Memory
256MiB
Difficulty
1
Tags
(None)
# Submissions
49
Accepted
34
Uploaded By