ans = 0 for s in input(): if 0 <= ord(s) - ord("0") <= 9: ans += ord(s) - ord("0") print(ans)