#include #include #include #include #include #include #include #include #include #include #include #include using namespace std; typedef pair pii; typedef vector vi; #define rep(i,x) for(int i=0;i<(int)(x);++i) int main(){ int ret = 0; string str; cin >> str; rep(i, str.size()) { if ('0' < str[i] && str[i] <= '9') ret += (int)str[i] - 48; } cout << ret << endl; return 0; }