#include <iostream>
using namespace std;
int cw(char t[], int s){
int count = 0;
for (int i = 0; i < s; i++){
if (t[i] == '_'){
count++;
}
}
return count;
}
int n;
int main(){
cin >> n;
char N[n];
int value = 1;
for (int i = 0; i < n; i++){
cin >> N[i];
}
const int c = cw(N, n);
value = 26 - (n-c);
for (int i = c; i > 1; i--){
value *= 26-i;
}
cout << value;
system("pause");
return 0;
}
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 3ms | 1880 KiB | ||||
2 | Accepted | 2ms | 2068 KiB | ||||
subtask2 | 10/10 | ||||||
3 | Accepted | 2ms | 2304 KiB | ||||
4 | Accepted | 2ms | 2552 KiB | ||||
5 | Accepted | 2ms | 2904 KiB | ||||
subtask3 | 20/20 | ||||||
6 | Accepted | 2ms | 3032 KiB | ||||
7 | Accepted | 2ms | 3160 KiB | ||||
8 | Accepted | 2ms | 3396 KiB | ||||
9 | Accepted | 2ms | 3372 KiB | ||||
10 | Accepted | 2ms | 3724 KiB | ||||
11 | Accepted | 2ms | 3968 KiB | ||||
subtask4 | 0/30 | ||||||
12 | Accepted | 2ms | 3940 KiB | ||||
13 | Wrong answer | 2ms | 4284 KiB | ||||
14 | Accepted | 2ms | 4540 KiB | ||||
15 | Wrong answer | 2ms | 4756 KiB | ||||
16 | Accepted | 2ms | 4880 KiB | ||||
17 | Wrong answer | 2ms | 4880 KiB | ||||
subtask5 | 0/40 | ||||||
18 | Accepted | 2ms | 5140 KiB | ||||
19 | Accepted | 2ms | 5116 KiB | ||||
20 | Accepted | 2ms | 5248 KiB | ||||
21 | Wrong answer | 2ms | 5224 KiB | ||||
22 | Wrong answer | 2ms | 5228 KiB | ||||
23 | Accepted | 2ms | 5024 KiB | ||||
24 | Accepted | 2ms | 5128 KiB |