#include #include #include using namespace std; int main() { int sum = 0; string s; cin >> s; for (int i = 0; i < (int)s.size(); i++) { if ('0' <= s[i] || s[i] <= '9') sum += stoi(&s[i]); } }