#include //#include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include //using namespace atcoder; using namespace std; using ll = long long; #define all(A) A.begin(),A.end() using vll = vector; #define rep(i, n) for (long long i = 0; i < (long long)(n); i++) using Graph = vector>>; vector seen; bool C = true; vector dist; ll mod =1e9+7; int op(int a, int b) { return min(a, b); } int e() { return int(1e9); } int main() { string S; cin >> S; ll an = 0; rep(s, S.size()) { if (S[s] >= '0' && S[s] <= '9') { an += S[s] - '0'; } } cout << an << endl; }