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

int main(){
	int n,a,b;
	cin>>n;
	a=n%10;
	b=n/10%10;
	if(a>b){
		cout<<a;
	}else{
		cout<<b;
	}
	
	}
	

/**************************************************************
	Problem: 1622
	User: linzihang
	Language: C++
	Result: Accepted
	Time:8 ms
	Memory:2072 kb
****************************************************************/