#P9471. Count Letters and Digits in a Fixed-Length String

    ID: 22620 Type: Default 1000ms 256MiB

Count Letters and Digits in a Fixed-Length String

Count Letters and Digits in a Fixed-Length String

Given a string \( s \) of length \(8\), count the number of alphabetic characters (both uppercase and lowercase) and digit characters in \( s \).

You are required to output two integers: the first is the count of letters (\( a \) to \( z \) and \( A \) to \( Z \)), and the second is the count of digits (\( 0 \) to \( 9 \)).

inputFormat

The input consists of a single line containing a string \( s \) of exactly 8 characters.

You can assume that \( s \) consists only of letters and digits.

outputFormat

Output two space-separated integers.

The first integer is the count of alphabetic characters and the second integer is the count of digit characters.

sample

aB3dF5gH
6 2