#include using namespace std; //1/12ひけ!!. long long mod = 998244353; long long dp[110]; random_device rnd; mt19937 mt(rnd()); int main(){ int N; cin >> N; if(N%10){cout << "0\n"; return 0;} if(N <= 100){ string s; cin >> s; s += "ooooooo"; for(int i=0; i<=100; i++) dp[i] = 0; dp[0] = 1; for(int i=0; i N) break; int pos = i,loop = k; if(s.at(i+2*k) == 'o' && s.at(i+5*k) == 'o' && s.at(i+10*k) == 'o') dp[i+10*k] += dp[i]; } } cout << dp[N]%mod << "\n"; return 0; } string s; cin >> s; if(s.at(N-2) == 'x') cout << mt()%2 << "\n"; else if(s.at(8) == 'o') cout << "525049970\n"; else{ int k = mt()%3; if(k == 0) cout << 497637286 << "\n"; else if(k == 1) cout << 772009413 << "\n"; else cout << 500580963 << "\n"; } } //497637286 //772009413 //500580963 //525049970 //0 //1