Competitions

# Week 4: November 30 – December 6. While Loop. Part 1

# Number of maximal digits

Find out how many times the maximum digit appears in positive integer **n**.

#### Input

One positive integer **n** (**n** < `10`

).^{18}

#### Output

Print how many times the maximum digit appears in positive integer **n**.

Input example #1

2354

Output example #1

1