#include using namespace std; int main() { int ans = 0; string S; cin >> S; for(auto c: S) { c -= '0'; if(c <= 9) ans += c; } cout << ans << endl; return 0; }