include<iostream>
using namespace std;
int max(int x, int y, int z)
{
int t;
if (x > y)
t = x;
else t = y;
if (z > t)
t = z;
return t;
}
int min(int x, int y, int z)
{
int t;
if (x < y)
t = x;
else t = y;
if (z < t)
t = z;
return t;
}
void main()
{
int a, b, c;
cin >> a >> b >> c;
cout << "最大值为" << max(a, b, c) << endl;
cout << "最小值为" << min(a, b, c) << endl;
}