main(){char s[10];int n=0;gets(s);for(int i=0;i<9;i++){if(s[i]=='0')n+=10;else n+=s[i]-48;}printf("%d\n",n);}