#C14250. Even Digit Sum
Even Digit Sum
Even Digit Sum
You are given a non-negative integer n. Your task is to compute the sum of all even digits in the decimal representation of n. If there are no even digits, the answer is 0.
The problem can be mathematically represented as:
\( S = \sum_{d \in D(n),\; d \bmod 2 = 0} d \)
where \( D(n) \) denotes the set of digits in the integer n.
Example:
- Input:
123456
— Even digits: 2, 4, 6, Sum = 12 - Input:
13579
— No even digits, Sum = 0
inputFormat
The input consists of a single line containing a non-negative integer n (0 ≤ n ≤ 1018).
The input is provided via stdin.
outputFormat
Output a single integer representing the sum of all even digits of n.
The output should be printed to stdout.
## sample2468
20