stablegradients/pie-gem5-bysrc huggingface dataset:
// Original C++ solution (slower):
#include <iostream>

#include <string.h>

#include <string>

#include <cstdlib>

#include <algorithm>

#include <vector>

using namespace std;



int main(){

	int n, a, b;

	scanf("%d%d%d", &n, &a, &b);

	printf("%d", min(n*a,b));

};


// Optimized solution to the same problem (faster):
#include<stdio.h>



class FIO

{

public:

    template<typename T>FIO& operator >>(T& x){ _R(x);return *this; }

    template<typename T>FIO& operator <<(T x){ _W(x);return *this; }

private:

    char f,c,a[25],i;

    template<typename T>inline void _R(T& x)

    {

        for(f=0;(c=getchar())<48;c==45&&(f=1));

        for(x=c^48;(c=getchar())>47;x=(x<<3)+(x<<1)+(c^48));

        if(f)x=-x;

    }

    template<typename T>inline void _W(T x)

    {

        if(sizeof(x)==1){ putchar(x);return; }

        if(x<0)putchar(45),x=-x;

        if(x>99) {

            for(i=0;x;x/=10)a[i++]=x%10;

            while(i--)putchar(a[i]+48);

        } else if(x>9) putchar(x/10+48),putchar(x%10+48);

        else putchar(x+48);

    }

}io;



int main()

{

    int n,a,b;

    io>>n>>a>>b;

    if(n*a<b)io<<n*a;

    else io<<b;

    return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <iostream>

#include <cstdio>

using namespace std;

	

int n,a,b;

int main(){

	scanf("%d%d%d",&n,&a,&b);

	if(n*a<b){ 

		printf("%d",(n*a)); 

	}else{

		printf("%d",b); 

	}

	return 0;

} 

// Optimized solution to the same problem (faster):
#include<stdio.h>



class FIO

{

public:

    template<typename T>FIO& operator >>(T& x){ _R(x);return *this; }

    template<typename T>FIO& operator <<(T x){ _W(x);return *this; }

private:

    char f,c,a[25],i;

    template<typename T>inline void _R(T& x)

    {

        for(f=0;(c=getchar())<48;c==45&&(f=1));

        for(x=c^48;(c=getchar())>47;x=(x<<3)+(x<<1)+(c^48));

        if(f)x=-x;

    }

    template<typename T>inline void _W(T x)

    {

        if(sizeof(x)==1){ putchar(x);return; }

        if(x<0)putchar(45),x=-x;

        if(x>99) {

            for(i=0;x;x/=10)a[i++]=x%10;

            while(i--)putchar(a[i]+48);

        } else if(x>9) putchar(x/10+48),putchar(x%10+48);

        else putchar(x+48);

    }

}io;



int main()

{

    int n,a,b;

    io>>n>>a>>b;

    if(n*a<b)io<<n*a;

    else io<<b;

    return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <cstdio>

#include <algorithm>

#include <cstring>

#include <cmath>

#include <vector>

using namespace std;

static_assert(sizeof(long) >= 8, "sizeof(long) >= 8");

constexpr int mod = 998244353;

long fac[100001], inv[100001];

int dp[10001];

int solve(int x, int y) {

    dp[0] = 1;

    for (int i = 1; i <= x; i++)

        for (int j = 1; j <= y; j++)

            dp[j] = (dp[j] + (long) i * dp[j - 1]) % mod;

    long ans = 0;

    for (int i = 0; i <= y; i++)

        ans = (ans + dp[i] * inv[x + i]) % mod;

    return ans * fac[x] % mod * fac[x] % mod * fac[y] % mod * fac[x + y] % mod;

}

char a[10001], b[10001];

int main() {

    fac[0] = 1;

    for (int i = 1; i <= 100000; i++)

        fac[i] = fac[i - 1] * i % mod;

    inv[100000] = 812950533;

    for (int i = 100000; i >= 1; i--)

        inv[i - 1] = inv[i] * i % mod;



    scanf("%s%s", a, b);

    int x = 0, y = 0;

    for (int i = 0; a[i]; i++)

        if (a[i] == '1')

            (b[i] == '0' ? x : y)++;

    printf("%d\n", solve(x, y));

}


// Optimized solution to the same problem (faster):
#include <cstdio>

using namespace std;

static_assert(sizeof(long) >= 8, "sizeof(long) >= 8");

constexpr int mod = 998244353;

int fac[20001], inv[20001];

int dp[10001];

int solve(int x, int y) {

    dp[0] = 1;

    for (int i = 1; i <= x; i++)

        for (int j = 1; j <= y; j++)

            dp[j] = (dp[j] + (long) i * dp[j - 1]) % mod;

    int ans = 0;

    for (int i = 0; i <= y; i++)

        ans = (ans + (long) dp[i] * inv[x + i]) % mod;

    return (long) ans * fac[x] % mod

                      * fac[x] % mod

                      * fac[y] % mod

                      * fac[x + y] % mod;

}

char a[10001], b[10001];

int main() {

    fac[0] = 1;

    for (int i = 1; i <= 20000; i++)

        fac[i] = (long) fac[i - 1] * i % mod;

    inv[20000] = 292343761;

    for (int i = 20000; i >= 1; i--)

        inv[i - 1] = (long) inv[i] * i % mod;



    scanf("%s%s", a, b);

    int x = 0, y = 0;

    for (int i = 0; a[i]; i++)

        if (a[i] == '1')

            (b[i] == '0' ? x : y)++;

    printf("%d\n", solve(x, y));

}


// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <bits/stdc++.h>

using namespace std;

int main()

{

    int exist[50000];

    for(int i = 0; i < 50000; i++)exist[i] = i + 1;

    int N;

    cin >> N;

    for(int i = 0; i < 50000; i++){

        if((int)((float)exist[i]*1.08) == N){

            cout << exist[i];

            return 0;

        }

    }

    cout << ":(";

    return 0;

}




// Optimized solution to the same problem (faster):
#include <iostream>

#include <iomanip>

typedef long long ll;

using namespace std;

const  ll INF = 1e9;

const  ll MOD = 1e9 + 7;

#define repi(i,n,init) for(ll i=init;i<(n);i++)



int main()

{

    int x;

    cin >> x;

    repi(i,x+1,1){

        if(int(i * 1.08) == x){

            cout << i << endl;

            return 0;

        }

    }

    cout << ":(" << endl;

    return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <iostream>



int main(void){

    int n, ans=0;

    std::cin >> n;



    for (int i=0; i<50001; ++i){

        if (i * 108 / 100 == n){

            ans = i;

        }

    }



    if (ans == 0){

        std::cout << ":(" << std::endl;

    } else {

        std::cout << ans << std::endl;

    }



    return 0;

}

// Optimized solution to the same problem (faster):
#include <iostream>



int main(void){

    int n, ans=0;

    std::cin >> n;



    for (int i=0; i<50001; ++i){

        if (i * 108 / 100 == n){

            ans = i;

            break;

        }

    }



    if (ans == 0){

        std::cout << ":(" << std::endl;

    } else {

        std::cout << ans << std::endl;

    }



    return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <bits/stdc++.h>

using namespace std;



#define ll long long

#define endl "\n"



ll n, m;

vector <ll> vis(200006,0);

vector <ll> ad[200006];



void add(ll x, ll y){

    ad[x].push_back(y);

    ad[y].push_back(x);

}



void dfs(ll node){

    vis[node]=1;

    for(ll x:ad[node]){

        if(!vis[x])

            dfs(x);

    }

}



void solve(){

    ll d, s, t;

    cin >> d >> t >> s;

    if(d<=t*s){

        cout << "Yes" << endl;

        return;

    }

    cout << "No" << endl;

    

}



int main(){

    ll t;

   // cin >> t;

    t=1;

    while(t--)

        solve();

    return 0;

}

// Optimized solution to the same problem (faster):
#include <bits/stdc++.h>

using namespace std;



#define ll long long

#define endl "\n"



void solve() {

  ll d, t, s;

  cin >> d >> t >> s;

  if (d <= t * s) {

    cout << "Yes\n";

    return;

  }

  cout << "No\n";

}



int main() {

  ll t;

  // cin >> t;

  t = 1;

  while (t--)

    solve();

  return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <cstdio>



const int MOD = 998244353;

const int INV2 = (MOD + 1) >> 1;



int add(int x, int y) {return (x + y >= MOD ? x + y - MOD : x + y);}

int sub(int x, int y) {return (x - y < 0 ? x - y + MOD : x - y);}

int mul(int x, int y) {return 1LL*x*y%MOD;}



int pow_mod(int b, int p) {

	int ret = 1;

	for(int i=p;i;i>>=1,b=mul(b,b))

		if( i & 1 ) ret = mul(ret,b);

	return ret;

}



struct node{

	int k, b;

	node() : k(0), b(0) {}

	node(int _k, int _b) : k(_k), b(_b) {}

	int get(int x) {return add(mul(k, x), b);}

	friend node operator + (node a, node b) {

		return node(add(a.k, b.k), add(a.b, b.b));

	}

	friend node operator - (node a, node b) {

		return node(sub(a.k, b.k), sub(a.b, b.b));

	}

	friend node operator * (node a, int k) {

		return node(mul(a.k, k), mul(a.b, k));

	}

	friend node operator / (node a, int k) {

		return a * pow_mod(k, MOD - 2);

	}

};



void fwt(node *A, int m, int type) {

	int n = (1 << m), f = (type == 1 ? 1 : INV2);

	for(int i=1;i<=m;i++) {

		int s = (1 << i), t = (s >> 1);

		for(int j=0;j<n;j+=s)

			for(int k=0;k<t;k++) {

				node x = A[j+k], y = A[j+k+t];

				A[j+k] = (x + y)*f, A[j+k+t] = (x - y)*f;

			}

	}

}



node A[1<<18], B[1<<18], C[1<<18], f[1<<18];



int main() {

	int N, M, S = 0; scanf("%d", &N), M = (1 << N);

	for(int i=0;i<M;i++) scanf("%d", &A[i].b), S = add(S, A[i].b);

	S = pow_mod(S, MOD - 2);

	for(int i=0;i<M;i++) A[i].b = sub(i == 0 ? 1 : 0, mul(A[i].b, S));

	for(int i=0;i<M;i++) B[i].b = 1;

	C[0].b = MOD - 1;

	fwt(A, N, 1), fwt(B, N, 1), fwt(C, N, 1);

	int tmp = mul(B[0].b, pow_mod(C[0].b, MOD-2));

	for(int i=1;i<M;i++)

		f[i] = (B[i] - C[i]*tmp) / A[i].b;

	f[0].k = 1; fwt(f, N, -1);

	int x = sub(0, mul(pow_mod(f[0].k, MOD-2), f[0].b));

	for(int i=0;i<M;i++) printf("%d\n", f[i].get(x));

}

// Optimized solution to the same problem (faster):
#include<cstdio>

#include<cstring>

#define retrun return

#define cpnst const

typedef long long ll;

cpnst ll mod=998244353,inv2=(mod+1)>>1;

ll qpow(ll x,ll k)

{ll r=1;for(;k;k>>=1,(x*=x)%=mod)if(k&1)(r*=x)%=mod;return r;}

ll N,A[1111111];

void FWT(ll*x,int op)

{

	for(register int i=1,ii,iii;i<N;i<<=1)

		for(ii=0;ii<N;ii+=(i<<1))

			for(iii=0;iii<i;iii++)

			{

				int px=ii+iii,py=px+i;

				ll vx=x[px]+x[py],vy=x[px]-x[py]+mod;

				if(op<0)vx*=inv2,vy*=inv2;

				x[px]=vx%mod,x[py]=vy%mod;

			}

}

ll C[1111111];

int main()

{

	scanf("%lld",&N),N=1<<N;

	register int i;

	ll S=0;

	for(i=0;i<N;i++)

		scanf("%lld",A+i),S+=A[i];

	S=qpow(S,mod-2);

	for(i=0;i<N;i++)(A[i]*=S)%=mod; 

	C[0]=N-1,A[0]=(mod-1+A[0])%mod;

	for(i=1;i<N;i++)C[i]=mod-1;

	FWT(C,1),FWT(A,1);

	for(i=0;i<N;i++)C[i]=qpow(A[i],mod-2)*C[i]%mod;

	FWT(C,-1);

	for(i=0;i<N;i++)printf("%lld\n",(C[i]-C[0]+mod)%mod);

}

/*

Just go for it.

*/

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <iostream>

#include <cstdio>

#define ll long long

using namespace std;

inline int read()

{

	int x = 0, f = 1; char ch = getchar();

	while(ch < '0' || ch > '9') {if(ch == '-') f = -1; ch = getchar();}

	while(ch >= '0' && ch <= '9') {x = (x << 3) + (x << 1) + (ch ^ 48); ch = getchar();}

	return x * f;

}

const int N = 1e6 + 1000,mod = 998244353;

ll n,sum,A[N],S[N];

ll ksm(ll x,ll y)

{

	ll res = 1; 

	for(;y;y >>= 1,x = x * x % mod) 

		if(y & 1) res = res * x % mod; 

	return res;

}

void Xor(ll *f,ll opt)

{

	ll a,b;

	for(int len = 2,mid = 1;len <= n;len <<= 1,mid <<= 1)

		for(int i = 0;i < n;i += len)

			for(int j = 0;j < mid;j ++)

			{

				a = f[i + j]; b = f[i + j + mid];

				f[i + j] = (a + b) % mod * opt % mod;

				f[i + j + mid] = (a - b) % mod * opt % mod;

			}

	for(int i = 0;i < n;i ++) f[i] = (f[i] + mod) % mod;

}

int main()

{

	n = read(); n = (1 << n);

	for(int i = 0;i < n;i ++) sum = sum + (A[i] = read());

	sum = ksm(sum,mod - 2); 

	for(int i = 0;i < n;i ++) A[i] = A[i] * sum % mod;

	A[0] --; if(A[0] < 0) A[0] += mod; 

	S[0] = n - 1; for(int i = 1;i < n;i ++) S[i] = mod - 1;

	Xor(S,1); Xor(A,1);

	for(int i = 0;i < n;i ++) A[i] = ksm(A[i],mod - 2) * S[i] % mod;

	Xor(A,(mod + 1) >> 1);

	ll x = mod - A[0];

	for(int i = 0;i < n;i ++) cout << ((x + A[i]) % mod + mod) % mod << "\n";

}

// Optimized solution to the same problem (faster):
#include<cstdio>

#include<cstring>

#define retrun return

#define cpnst const

typedef long long ll;

cpnst ll mod=998244353,inv2=(mod+1)>>1;

ll qpow(ll x,ll k)

{ll r=1;for(;k;k>>=1,(x*=x)%=mod)if(k&1)(r*=x)%=mod;return r;}

ll N,A[1111111];

void FWT(ll*x,int op)

{

	for(register int i=1,ii,iii;i<N;i<<=1)

		for(ii=0;ii<N;ii+=(i<<1))

			for(iii=0;iii<i;iii++)

			{

				int px=ii+iii,py=px+i;

				ll vx=x[px]+x[py],vy=x[px]-x[py]+mod;

				if(op<0)vx*=inv2,vy*=inv2;

				x[px]=vx%mod,x[py]=vy%mod;

			}

}

ll C[1111111];

int main()

{

	scanf("%lld",&N),N=1<<N;

	register int i;

	ll S=0;

	for(i=0;i<N;i++)

		scanf("%lld",A+i),S+=A[i];

	S=qpow(S,mod-2);

	for(i=0;i<N;i++)(A[i]*=S)%=mod; 

	C[0]=N-1,A[0]=(mod-1+A[0])%mod;

	for(i=1;i<N;i++)C[i]=mod-1;

	FWT(C,1),FWT(A,1);

	for(i=0;i<N;i++)C[i]=qpow(A[i],mod-2)*C[i]%mod;

	FWT(C,-1);

	for(i=0;i<N;i++)printf("%lld\n",(C[i]-C[0]+mod)%mod);

}

/*

Just go for it.

*/

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <cstdio>

#include <cstring>

#include <iostream>

#include <algorithm>

using namespace std;

#define ll long long

#define mod 998244353

#define inv2 499122177

void Read(int &p)

{

	p = 0;

	char c = getchar();

	for (; c < '0' || c > '9'; c = getchar());

	for (; c >= '0' && c <= '9'; c = getchar())p = p * 10 + c - '0';

}

int Add(int a, int b)

{

	int c = a + b;

	if (c >= mod)

		c -= mod;

	return c;

}

int Sub(int a, int b)

{

	int c = a - b;

	if (c < 0)

		c += mod;

	return c;

}

int Pow(int a, int k)

{

	if (!k)

		return 1;

	int p = Pow(a, k / 2);

	if (k & 1)

		return (ll)p * p % mod * a % mod;

	return (ll)p * p % mod;

}

int A[1 << 18], B[1 << 18], C[1 << 18], D[1 << 18];

int n, s;

void FWT(int *A, int w)

{

	if (w == 1)

		return;

	FWT(A, w >> 1);

	FWT(A + (w >> 1), w >> 1);

	for (int i = 0; i < (w >> 1); i++)

	{

		int x = A[i], y = A[i + (w >> 1)];

		A[i] = Add(x, y);

		A[i + (w >> 1)] = Sub(x, y);

	}

}

void IFWT(int *A, int w)

{

	if (w == 1)

		return;

	IFWT(A, w >> 1);

	IFWT(A + (w >> 1), w >> 1);

	for (int i = 0; i < (w >> 1); i++)

	{

		int x = A[i], y = A[i + (w >> 1)];

		A[i] = (ll)Add(x, y) * inv2 % mod;

		A[i + (w >> 1)] = (ll)Sub(x, y) * inv2 % mod;

	}

}

int main()

{

	Read(n);

	for (int i = 0; i < (1 << n); i++)

		Read(D[i]), s = Add(s, D[i]);

	s = Pow(s, mod - 2);

	for (int i = 0; i < (1 << n); i++)

		A[i] = D[i] = (ll)D[i] * s % mod;

	B[0] = (1 << n) - 1;

	for (int i = 1; i < (1 << n); i++)

		B[i] = mod - 1;

	A[0] = Sub(A[0], 1);

	FWT(A, 1 << n);

	FWT(B, 1 << n);

	int x = 0, p = 0;

	for (int i = 0; i < (1 << n); i++)

	{

		if (A[i] == 0)

			x = i;

		C[i] = (ll)Pow(A[i], mod - 2) * B[i] % mod;

	}

	IFWT(C, 1 << n);

	p = (ll)Sub(0, C[0]) * (1 << n) % mod;

	FWT(C, 1 << n);

	C[x] = p;

	IFWT(C, 1 << n);

	for (int i = 0; i < (1 << n); i++)

		printf("%d\n", C[i]);

}


// Optimized solution to the same problem (faster):
#include<cstdio>

#include<cstring>

#define retrun return

#define cpnst const

typedef long long ll;

cpnst ll mod=998244353,inv2=(mod+1)>>1;

ll qpow(ll x,ll k)

{ll r=1;for(;k;k>>=1,(x*=x)%=mod)if(k&1)(r*=x)%=mod;return r;}

ll N,A[1111111];

void FWT(ll*x,int op)

{

	for(register int i=1,ii,iii;i<N;i<<=1)

		for(ii=0;ii<N;ii+=(i<<1))

			for(iii=0;iii<i;iii++)

			{

				int px=ii+iii,py=px+i;

				ll vx=x[px]+x[py],vy=x[px]-x[py]+mod;

				if(op<0)vx*=inv2,vy*=inv2;

				x[px]=vx%mod,x[py]=vy%mod;

			}

}

ll C[1111111];

int main()

{

	scanf("%lld",&N),N=1<<N;

	register int i;

	ll S=0;

	for(i=0;i<N;i++)

		scanf("%lld",A+i),S+=A[i];

	S=qpow(S,mod-2);

	for(i=0;i<N;i++)(A[i]*=S)%=mod; 

	C[0]=N-1,A[0]=(mod-1+A[0])%mod;

	for(i=1;i<N;i++)C[i]=mod-1;

	FWT(C,1),FWT(A,1);

	for(i=0;i<N;i++)C[i]=qpow(A[i],mod-2)*C[i]%mod;

	FWT(C,-1);

	for(i=0;i<N;i++)printf("%lld\n",(C[i]-C[0]+mod)%mod);

}

/*

Just go for it.

*/

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include<bits/stdc++.h>

#define maxn 300005

using namespace std;

const int mod = 998244353;

int n,N,p[maxn],E[maxn];

int Pow(int a,int b){int s=1;for(;b;b>>=1,a=1ll*a*a%mod) b&1&&(s=1ll*s*a%mod); return s;}

int upd(int x){return x+(x>>31&mod);}

void FWT(int *a,int len,int flg){

	for(int i=2,l=1,v;i<=len;l=i,i<<=1)

		for(int j=0;j<len;j+=i)

			for(int k=j;k<j+l;k++)

				v=a[k],a[k]=upd(v+a[k+l]-mod),a[k+l]=upd(v-a[k+l]);

	if(flg^1) for(int i=0,Inv=Pow(len,mod-2);i<len;i++) a[i]=1ll*a[i]*Inv%mod;

}

int main()

{

	scanf("%d",&n),N=1<<n; int s=0;

	for(int i=0;i<N;i++) scanf("%d",&p[i]),s=upd(s+p[i]-mod);

	s=Pow(s,mod-2);

	for(int i=0;i<N;i++) p[i]=1ll*p[i]*s%mod;

	FWT(p,N,1);

	for(int i=1;i<N;i++) E[i]=1ll*N*Pow(upd(p[i]-1),mod-2)%mod;

	FWT(E,N,-1);

	int x=mod-E[0];

	for(int i=0;i<N;i++) printf("%d\n",upd(E[i]+x-mod));

}

// Optimized solution to the same problem (faster):
#include<cstdio>

#include<cstring>

#define retrun return

#define cpnst const

typedef long long ll;

cpnst ll mod=998244353,inv2=(mod+1)>>1;

ll qpow(ll x,ll k)

{ll r=1;for(;k;k>>=1,(x*=x)%=mod)if(k&1)(r*=x)%=mod;return r;}

ll N,A[1111111];

void FWT(ll*x,int op)

{

	for(register int i=1,ii,iii;i<N;i<<=1)

		for(ii=0;ii<N;ii+=(i<<1))

			for(iii=0;iii<i;iii++)

			{

				int px=ii+iii,py=px+i;

				ll vx=x[px]+x[py],vy=x[px]-x[py]+mod;

				if(op<0)vx*=inv2,vy*=inv2;

				x[px]=vx%mod,x[py]=vy%mod;

			}

}

ll C[1111111];

int main()

{

	scanf("%lld",&N),N=1<<N;

	register int i;

	ll S=0;

	for(i=0;i<N;i++)

		scanf("%lld",A+i),S+=A[i];

	S=qpow(S,mod-2);

	for(i=0;i<N;i++)(A[i]*=S)%=mod; 

	C[0]=N-1,A[0]=(mod-1+A[0])%mod;

	for(i=1;i<N;i++)C[i]=mod-1;

	FWT(C,1),FWT(A,1);

	for(i=0;i<N;i++)C[i]=qpow(A[i],mod-2)*C[i]%mod;

	FWT(C,-1);

	for(i=0;i<N;i++)printf("%lld\n",(C[i]-C[0]+mod)%mod);

}

/*

Just go for it.

*/

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <cstdio>



const int MOD = 998244353;

const int INV2 = (MOD + 1) >> 1;



int add(int x, int y) {return (x + y >= MOD ? x + y - MOD : x + y);}

int sub(int x, int y) {return (x - y < 0 ? x - y + MOD : x - y);}

int mul(int x, int y) {return 1LL*x*y%MOD;}



int pow_mod(int b, int p) {

	int ret = 1;

	for(int i=p;i;i>>=1,b=mul(b,b))

		if( i & 1 ) ret = mul(ret,b);

	return ret;

}



struct node{

	int k, b;

	node() : k(0), b(0) {}

	node(int _k, int _b) : k(_k), b(_b) {}

	int get(int x) {return add(mul(k, x), b);}

	friend node operator + (node a, node b) {

		return node(add(a.k, b.k), add(a.b, b.b));

	}

	friend node operator - (node a, node b) {

		return node(sub(a.k, b.k), sub(a.b, b.b));

	}

	friend node operator * (node a, int k) {

		return node(mul(a.k, k), mul(a.b, k));

	}

	friend node operator / (node a, int k) {

		return a * pow_mod(k, MOD - 2);

	}

};



void fwt(node *A, int m, int type) {

	int n = (1 << m), f = (type == 1 ? 1 : INV2);

	for(int i=1;i<=m;i++) {

		int s = (1 << i), t = (s >> 1);

		for(int j=0;j<n;j+=s)

			for(int k=0;k<t;k++) {

				node x = A[j+k], y = A[j+k+t];

				A[j+k] = (x + y)*f, A[j+k+t] = (x - y)*f;

			}

	}

}



node A[1<<18], B[1<<18], C[1<<18], f[1<<18];



int main() {

	int N, M, S = 0; scanf("%d", &N), M = (1 << N);

	for(int i=0;i<M;i++) scanf("%d", &A[i].b), S = add(S, A[i].b);

	S = pow_mod(S, MOD - 2);

	for(int i=0;i<M;i++) A[i].b = sub(i == 0 ? 1 : 0, mul(A[i].b, S));

	for(int i=0;i<M;i++) B[i].b = 1;

	C[0].b = MOD - 1;

	fwt(A, N, 1), fwt(B, N, 1), fwt(C, N, 1);

	int tmp = mul(B[0].b, pow_mod(C[0].b, MOD-2));

	for(int i=1;i<M;i++)

		f[i] = (B[i] - C[i]*tmp) / A[i].b;

	f[0].k = 1; fwt(f, N, -1);

	int x = sub(0, mul(pow_mod(f[0].k, MOD-2), f[0].b));

	for(int i=0;i<M;i++) printf("%d\n", f[i].get(x));

}

// Optimized solution to the same problem (faster):
#include<bits/stdc++.h>

#define ll long long

using namespace std;

const int mod=998244353;

const int N=262150;

int n;

int p[N],f[N];

inline ll qpow(ll x,int k,ll r=1){

	for(;k;k>>=1,x=x*x%mod) if(k&1) r=r*x%mod;

	return r;

}

inline void fwt(int *a,int len,int opt){

	for(int i=1;i<len;i<<=1) for(int j=0;j<len;j+=i<<1) for(int k=0;k<i;++k){

		int x=a[j+k],y=a[j+k+i];

		a[j+k]=(x+y)%mod; a[j+k+i]=(x-y+mod)%mod;

	}

	if(~opt) return ;

	int inv=qpow(len,mod-2);

	for(int i=0;i<len;++i) a[i]=1ll*a[i]*inv%mod;

}

int main(){

	scanf("%d",&n); int len=1<<n,sum=0;

	for(int i=0;i<len;++i) scanf("%d",&p[i]),sum+=p[i]; sum=qpow(sum,mod-2);

	for(int i=0;i<len;++i) p[i]=1ll*p[i]*sum%mod; (p[0]+=mod-1)%=mod;

	for(int i=0;i<len;++i) f[i]=mod-1; (f[0]+=len)%=mod;

	fwt(f,len,1); fwt(p,len,1); sum=0;

	for(int i=1;i<len;++i) f[i]=f[i]*qpow(p[i],mod-2)%mod,(sum+=f[i])%=mod;

	f[0]=mod-sum; fwt(f,len,-1);

	for(int i=0;i<len;++i) printf("%d\n",f[i]);

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include<iostream>

using namespace std;

int main()

{

    int n,m;

    cin>>n>>m;

    if(n==m){cout<<"Yes"<<endl;}

    else{cout<<"No"<<endl;}

    return 0;

}

// Optimized solution to the same problem (faster):
#include<stdio.h>



int main(){

	

	int N, M;

	scanf("%d %d", &N, &M);

	(N == M) ? puts("Yes") : puts("No");

	

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <bits/stdc++.h>



using namespace std;



int main() {



    int n,m;

    cin>>n>>m;

    n==m?cout<<"Yes"<<endl:cout<<"No"<<endl;



    return 0;

}


// Optimized solution to the same problem (faster):
#include<stdio.h>



int main(){

	

	int N, M;

	scanf("%d %d", &N, &M);

	(N == M) ? puts("Yes") : puts("No");

	

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <iostream>

using namespace std;



int main() {

	int n,m;

	cin>>n>>m;

	if(n==m){

	    cout<<"Yes"<<endl;

	}

	else{

	    cout<<"No"<<endl;

	}

	return 0;

}


// Optimized solution to the same problem (faster):
#include<stdio.h>



int main(){

	

	int N, M;

	scanf("%d %d", &N, &M);

	(N == M) ? puts("Yes") : puts("No");

	

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include<bits/stdc++.h>

using namespace std;

int main()

{

      ios::sync_with_stdio(false);

      cin.tie(0);

    int n,m;

    cin>>n>>m;

    if(n==m){

        cout<<"Yes";

    }

    else

        cout<<"No";

    return 0;

}


// Optimized solution to the same problem (faster):
#include<stdio.h>



int main(){

	

	int N, M;

	scanf("%d %d", &N, &M);

	(N == M) ? puts("Yes") : puts("No");

	

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include<iostream>

using namespace std;

int main()

{

    int N,M;

    cin>>N>>M;

    if(N==M){

        cout<<"Yes";

    }else{

        cout<<"No";

    }

return 0;}


// Optimized solution to the same problem (faster):
#include<stdio.h>



int main(){

	

	int N, M;

	scanf("%d %d", &N, &M);

	(N == M) ? puts("Yes") : puts("No");

	

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include<bits/stdc++.h>

typedef long long ll;

using namespace std;

#define fi0 for(ll i=0;i<n;i++)

void solve()

{

    int n,m;

    cin>>n>>m;

    if(n==m){

        cout<<"Yes\n";

    }

    else{

        cout<<"No\n";

    }

}

int main()

{

   /// int t;cin>>t;while(t--){

        solve();



}


// Optimized solution to the same problem (faster):
#include<stdio.h>



int main(){

	

	int N, M;

	scanf("%d %d", &N, &M);

	(N == M) ? puts("Yes") : puts("No");

	

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
//BISMILLAHIR RAHMANIR RAHIM



#include <bits/stdc++.h>

#define loop(i,n) for(int i=0;i<n;i++)

#define pi acos(-1.00)



using namespace std;







int main()

{

    int n,m;

    cin>>n>>m;

    if(n==m)

        cout<<"Yes"<<endl;

    else

        cout<<"No"<<endl;







}




// Optimized solution to the same problem (faster):
#include<stdio.h>



int main(){

	

	int N, M;

	scanf("%d %d", &N, &M);

	(N == M) ? puts("Yes") : puts("No");

	

	return 0;

}

// Fastest known solution for this problem:
// Original C++ solution (slower):
#include <iostream>



using namespace std;



int main()

{

    int N ,M;

    cin>>N>>M;

    if (M==N)

        cout<<"Yes";

    else

        cout<<"No";

    return 0;

}


// Optimized solution to the same problem (faster):
#include<stdio.h>

int main(){

	int N;

	int M;

	scanf("%d",&N);

	scanf("%d",&M);

	

	if(N==M){

		printf("Yes\n");

	}

	else{

		printf("No\n");

	}

	

	

	

	

	return 0;

}

// Fastest known solution for this problem: