func_code_string: #include <bits/stdc++.h>   using namespace std;   const int inf = 0x3f3f3f3f, mod = 998244353;   const long long INF = 0x3f3f3f3f3f3f3f3fLL;   const double pi = acosl(-1.), eps = 1e-9;   inline void sum(int &a, int b) {     a += b;     if (a >= mod) a -= mod;   }   const int NN = 1000100;   char A[NN], L[NN], R[NN];   int n, ln, rn, B[NN];   void zval(const char *s, int len, int *z) {     z[0] = 0;     for (int b = 0, i = 1; i < len; i++) {       z[i] = max(min(z[i - b], z[b] + b - i), 0);       while (s[i + z[i]] == s[z[i]]) z[i]++;       if (i + z[i] > b + z[b]) b = i;     }     z[0] = len;   }   char zl[NN << 1], zr[NN << 1];   int zL[NN << 1], zR[NN << 1];   int main() {     scanf( %s %s %s , A + 1, L, R);     n = strlen(A + 1);     ln = strlen(L);     rn = strlen(R);     for (int i = 0; i < ln; i++) zl[i] = L[i];     zl[ln] =  * ;     for (int i = ln + 1; i <= ln + n; i++) zl[i] = A[i - ln];     zval(zl, ln + n + 1, zL);     for (int i = 0; i < rn; i++) zr[i] = R[i];     zr[rn] =  * ;     for (int i = rn + 1; i <= rn + n; i++) zr[i] = A[i - rn];     zval(zr, rn + n + 1, zR);     B[n + 1] = 1;     for (int i = n, st, ed; i; i--) {       B[i] = B[i + 1];       if (A[i] ==  0 ) {         if (ln == 1 && L[0] ==  0 ) {           st = ed = i + 1;         } else           continue;       } else {         st = i + ln;         if (st > n + 1) continue;         int p = zL[ln + i];         if (p < ln) {           if (A[i + p] < L[p]) st++;         }         if (st > n + 1) continue;         ed = i + rn;         if (ed <= n + 1) {           p = zR[rn + i];           if (p < rn) {             if (A[i + p] > R[p]) ed--;           }         } else           ed = n + 1;         if (ed < st) continue;       }       int d = B[st] - B[ed + 1];       if (d < 0) d += mod;       sum(B[i], d);       if (i == 1) {         cout << d << endl;         return 0;       }     }     puts( 0 );     return 0;   }   