import re S = input() sum = 0 temp = re.findall('[0-9]', S) for i in temp: sum += int(i) print(sum)