import std.bigint,std.conv,std.stdio,std.string;int M=10^^9+7,S=2600000;long z,a,e;void f(int n){z=0;foreach(c; ` !BCJ6J[;'Y" W!%=4EW6JWG?&ZAH-Q#OHU6X0RVW+6@T4[!$\5P,@AB7^)))E7<5Y4K=M!G?+M8OA#'SLLB\?E[-"/-<%4[?UD([Z$[4EK60KRD:@2RLA1?:)(?'7JL#E$S(?ZI,B($$S];RKU0MO@/)HLI):;'H,YWM114/CSC_)V:,O>[ _K#,V)7G14W-3R#U >SSG4NX/H='B#II]T"#P5 NC<7%+2U#,MC&X77D\8 %N]Y,!Y^$RP:W6I'0*VH-E)6\0X!U9R"M^@8A80/G8D"OH3J!Z4 *UYHI?RC[1U0')!/[ZZ8*MW/RQ%S[4U91R%F6EKW?8Y7AP.!3$SOUKI:NY/;L3A@H?_5-&O%N4W:>MB,(9GC*_@4=RPF0J6(;&0G:=[;,HUHEP5[O28#YS!7_UVJ9AH/U?\5*^4OLP0I"R2D5:V6\#]!J$J*R&A7G(+0MJ@]BE".=OY'87O!C33'5+]+GOY(C,YWL,5WD2>H=S9#L'#,]P)%J3-50!7SD6^&7?Q;SR%VJEQH&JP]$/(Y_@AM"["FZH;]B_?/+L\H#UJW"Z$*_&'V>2XSXP!1,ZD+!V11W;VBK'E+OW^NI*=3E#3!C.>@6PP)L#7N+48)-6E#L2* /5T<>T@'0"9:TQ!/X1N'J-W:4!5@6[WYCKY[4N4O]CA/A;5]:RB HO,A)#-$0Z_$B?6Y2P8!6.0[U4HCM%?[7"4_,A?215:8[<),XPYY00(,ZG9F:V40@ >>K&P0-OVNV@127HVD?TMFA?:RFOI5LAVQ?WYO@8%M2EZAIHI _W-H>E!:9Q>YV'P5[",LL1]'Z30&6O(#RNWW+.K.Q<\[""BQ-Q83=>CEVS$'MW8SM>VTSUI\B^DQ/E.1\C=0&&l/M==r/M){f(r%M);a=z;f(l%M);for(e=M-2;e;e/=2,z=z*z%M)if(e&1)a=a*z%M;}a.writeln;}}