Problem Statement | |||||||||||||
A string s is called an IOI string if it satisfies the following two conditions:
Return the number of different IOI strings that can be formed, modulo 1,000,000,007 (1E9+7). | |||||||||||||
Definition | |||||||||||||
| |||||||||||||
Constraints | |||||||||||||
| - | mask will contain between 1 and 50 elements, inclusive. | ||||||||||||
| - | Each element of mask will contain between 1 and 50 characters, inclusive. | ||||||||||||
| - | Each character in mask will be uppercase 'I' or uppercase 'O' or '?'. | ||||||||||||
Examples | |||||||||||||
| 0) | |||||||||||||
| |||||||||||||
| 1) | |||||||||||||
| |||||||||||||
| 2) | |||||||||||||
| |||||||||||||
| 3) | |||||||||||||
| |||||||||||||
| 4) | |||||||||||||
| |||||||||||||