#include <bits/stdc++.h>
using namespace std;
const int N = 100005;
const int inf = 1e9 + 7;
inline void read(int &x) {
  x = 0;
  char ch = getchar();
  while (ch < '0') ch = getchar();
  while (ch >= '0') {
    x = x * 10 + ch - 48;
    ch = getchar();
  }
}
unsigned int f[2][N];
char s[N];
const unsigned int pp = 25;
int main() {
  int n;
  read(n);
  scanf("%s", s + 1);
  f[0][0] = 1;
  register int cur = 0, nxt, up, j, fk;
  for (register int i = (1); i <= (n); i++) {
    nxt = cur ^ 1;
    up = min(i, n - i + 1);
    fk = (n - i) & 1;
    for (j = 2 - fk; j <= up; j += 2) {
      if (s[i] == '?')
        f[nxt][j] = f[cur][j + 1] + pp * f[cur][j - 1];
      else
        f[nxt][j] = f[cur][j - 1];
    }
    if (s[i] == '?')
      f[nxt][0] = f[cur][1];
    else
      f[nxt][0] = 0;
    cur = nxt;
  }
  long long rp = f[cur][0];
  printf("%I64d\n", rp);
  return 0;
}
