#include<bits/stdc++.h>
using namespace std;
int main(){
	int x,s,g,sh;
	cin>>x;
	g=x%10;
	sh=x/10;
    s=g+sh;
	cout<<s;
    
}
/**************************************************************
	Problem: 1605
	User: wangyiyang
	Language: C++
	Result: Accepted
	Time:8 ms
	Memory:2072 kb
****************************************************************/