Skip to main content
Tuesday (24.11.2026) at 20:00: ALGOR Contest: Round #4 (Special Challenge) starts!

~/algor $ cat problems/string-raqamlar-yigindisi

Sum of digits in a string

Easy 1000 ms 128 MB 24%
Share

A string $s$ of lowercase Latin letters and digits is given. Find the sum of all digits in the string.

Extracting the digits from the string and computing their sum

Input

One line containing the string $s$.

Output

One integer ($0$ if there are no digits).

Note

$1 \le |s| \le 10^{5}$
$s$ consists only of the letters a–z and the digits 0–9

Examples

Input #1
a1b23
Output #1
6
Input #2
algor
Output #2
0

Sign in to submit a solution

Signing up is free and takes a minute.