e-olymp
favorite We need a little bit of your help to keep things running, click on this banner to learn more
Competitions

Week 6: December 14 - 20. Char arrays 1

Password

We call a crypto-password persistent if 5 criteria are satisfied:

  1. Password contains lowercase Latin letters

  2. Password contains uppercase Latin letters

  3. Password contains digits

  4. Password contains symbols: ! " # $ % & ' ( ) * +

  5. The length of the password is not less than 8 symbols

Determine how many crypto stability criteria are satisfied for this password.

Input

One line consists of no more than 100 symbols.

Output

Print the number of crypto stability criteria that satisfies the password.

Time limit 1 second
Memory limit 128 MiB
Input example #1
1aA
Output example #1
3
Input example #2
AaBbCc12
Output example #2
4
Input example #3
AAAaaaAAA
Output example #3
3
Input example #4
#Abc23$$$
Output example #4
5