#include<bits/stdc++.h>
typedef long long ll;
const double pi=acos(-1);
#define FILE "read"
#define MAXN 300010
int n,m,H(0),L(1),R[MAXN];
inline int read(){
int x=0;int f=1;char ch=getchar();
while(!isdigit(ch)) {if(ch=='-') f=-1;ch=getchar();}
while(isdigit(ch)) {x=x*10+ch-'0';ch=getchar();}
return x*f;
}
struct complex{
double r,v;
complex(double a=0,double b=0):r(a),v(b){}
inline complex operator+(const complex &b){return complex(r+b.r,v+b.v);}
inline complex operator-(const complex &b){return complex(r-b.r,v-b.v);}
inline complex operator*(const complex &b){return complex(r*b.r-v*b.v,r*b.v+v*b.r);}
}a[MAXN],b[MAXN],w[MAXN];
inline void swap(complex &a,complex &b){complex t(a);a=b;b=t;}
void FFT(complex *a,int f){
for(int i=0;i<L;++i) if(i<R[i]) swap(a[i],a[R[i]]);
for(int len=2;len