N=int(input()) S=input() Mod=10**9+7 yukicoder=set("yukicoder") Ind={a:i for i,a in enumerate("yukicoder")} DP=[[0,0] for _ in range(10)] DP[0][0]=1 for s in S: E=DP DP=[[0,0] for _ in range(10)] for level in range(10): for mode in [0,1]: DP[level][mode]=E[level][mode] if s=="?": for level in range(9): DP[level+1][1]+=DP[level][0] elif s in yukicoder: level=Ind[s] DP[level+1][0]+=DP[level][0] DP[level+1][1]+=DP[level][1] for level in range(10): DP[level][0]%=Mod DP[level][1]%=Mod print(sum(DP[9])%Mod)