How Many Distinct Letters

No attempts yetTime limit1sMemory limit128 MB

Problem

"The quick brown fox jumped over the lazy dogs."

This sentence is famous for containing every letter of the alphabet at least once; that is, it uses all 26 distinct letters.

For each sentence, ignore spaces, digits, and special characters, and count how many distinct letters of the alphabet appear. Uppercase and lowercase are treated as the same letter. For example, 'A' equals 'a'.

Input

Sentences are given over multiple lines. Each sentence is at most 250 characters long.

Each sentence contains at least one non-space character (which is not necessarily a letter).

The last line of the input contains only #, which marks the end of the input.

Output

For each sentence, print the number of distinct letters that appear, one per line.