#include<stdio.h>
#define M 4
#define N 4
int main()
{
int matrix[M][N] = { {2,3,9,5},{6,7,8,3},{8,5,6,4},{2,1,7,3} };
int max, min;
int i, j, p, k;
for (i = 0; i < M; i++)
{
for (j = 0; j < N; j++)
{
printf("%3d", matrix[i][j]);
}
printf("\n");
}
for (i = 0; i < M; i++)
{
max = matrix[i][0];
for (j = 1; j < N; j++)
{
if (max < matrix[i][j])
{
max = matrix[i][j];
k = j;
}
}
min = max;
for (j = 0; j < M; j++)
{
if (min > matrix[j][k])
{
p = j;
}
}
if (max == min)
{
printf("鞍点:matrix[%d][%d]=%d\n", i, k, max);
}
}
}