# -*- coding: utf-8 -*- from __future__ import absolute_import from __future__ import unicode_literals S = raw_input() N = 0 for i in xrange(len(S)): if S[i].isdigit() is True: N += int(S[i]) print N