#include using namespace std; typedef long long ll; #define rep(i,n) for(int (i)=0;(i)<(int)(n);++(i)) #define each(itr,c) for(__typeof(c.begin()) itr=c.begin(); itr!=c.end(); ++itr) #define all(x) (x).begin(),(x).end() #define pb push_back #define fi first #define se second const int mod=1000000009; string m,d; int dp[202][1900][2]; int a[1900]={0}, b[1900]={0}; int main() { cin >>m >>d; int M=m.size(), D=d.size(); // about m memset(dp,0,sizeof(dp)); dp[0][0][0]=1; rep(i,M) { rep(j,1900) { for(int k=0; k