import java.io.*; import java.util.*; public class Main { static final int MOD = 1000000007; public static void main(String[] args) throws Exception { Scanner sc = new Scanner(); int n = sc.nextInt(); String yukicoder = "yukicoder"; int length = yukicoder.length(); HashMap idxes = new HashMap<>(); for (int i = 0; i < length; i++) { idxes.put(yukicoder.charAt(i), i + 1); } int[][] dp = new int[length + 1][2]; dp[0][0] = 1; for (char c : sc.next().toCharArray()) { if (idxes.containsKey(c)) { int x = idxes.get(c); dp[x][0] += dp[x - 1][0]; dp[x][0] %= MOD; dp[x][1] += dp[x - 1][1]; dp[x][1] %= MOD; } else if (c == '?') { for (int i = 1; i <= length; i++) { dp[i][1] += dp[i - 1][0]; dp[i][1] %= MOD; } } } System.out.println((dp[length][0] + dp[length][1]) % MOD); } } class Scanner { BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); StringTokenizer st = new StringTokenizer(""); public Scanner() throws Exception { } public int nextInt() throws Exception { return Integer.parseInt(next()); } public long nextLong() throws Exception { return Long.parseLong(next()); } public double nextDouble() throws Exception { return Double.parseDouble(next()); } public String next() throws Exception { if (!st.hasMoreTokens()) { st = new StringTokenizer(br.readLine()); } return st.nextToken(); } }