S = list(raw_input()) SUM = 0 for i in S: try: SUM += int(i) except: pass print(str(SUM))