#include int main() { char str[10000]; int a = 0; scanf("%s", &str); for (int i = 0; str[i] != '\0'; i++) { if (str[i] <= '9' && str[i] >= '0') { a += (str[i] - '0'); } } printf("%d\n", a); return 0; }