import sys, math sys.set_int_max_str_digits(0) S = input() ans = 0 suji = '123456789' for s in S: if s in suji: ans += int(s) print(ans)