from collections import * from itertools import * from functools import * from heapq import * import sys,math input = sys.stdin.readline S = list(input())[:-1] nums = [str(i) for i in range(10)] ans = 0 for s in S: if s in nums: ans += int(s) print(ans)