S = raw_input() ans = 0 for s in S: try: ans += int(s) except: continue print ans