# include<iostream> using namespace std; int main(){ int n,m,c,d; cin>>n; c=n%10; d=n%100/10; m=n/100; cout<<c+d+m; return 0; }