import re S = input() s = re.sub("\\D", "", S) ss = list(map(int, s)) print(sum(ss))