score_str = input() outcome = 0 for c in score_str: score = int(c) if score == 0: outcome += 10 else: outcome += score input(outcome)