#include<bits/stdc++.h>
using namespace std;
int main(){
int n,g,s;
cin>>n;
g=n%10;
s=n/10;
int max=g;
if (max<s){
max=s;
}
printf("%d",max);
return 0;
}
/**************************************************************
Problem: 1622
User: xiaojingxuan
Language: C++
Result: Accepted
Time:8 ms
Memory:2072 kb
****************************************************************/