varsnarkjs=function(A){"use strict";constI=[0,1,2,2,3,3,3,3,4,4,4,4,4,4,4,4];functiong(A,I){returnI&&10!=I?16==I?"0x"==A.slice(0,2)?BigInt(A):BigInt("0x"+A):void0:BigInt(A)}constQ=g;functionC(A,I){returnBigInt(A)<<BigInt(I)}functionB(A,I){returnBigInt(A)>>BigInt(I)}constE=C,i=B;vart=Object.freeze({__proto__:null,fromString:g,e:Q,fromArray:function(A,I){letg=0n;I=BigInt(I);for(letQ=0;Q<A.length;Q++)g=g*I+BigInt(A[Q]);returng},bitLength:function(A){constg=A.toString(16);return4*(g.length-1)+I[parseInt(g[0],16)]},isNegative:function(A){returnBigInt(A)<0n},isZero:function(A){return!A},shiftLeft:C,shiftRight:B,shl:E,shr:i,isOdd:function(A){return1n==(1n&BigInt(A))},naf:function(A){letI=BigInt(A);constg=[];for(;I;){if(1n&I){constA=2-Number(I%4n);g.push(A),I-=BigInt(A)}elseg.push(0);I>>=1n}returng},bits:function(A){letI=BigInt(A);constg=[];for(;I;)1n&I?g.push(1):g.push(0),I>>=1n;returng},toNumber:function(A){if(A>BigInt(Number.MAX_SAFE_INTEGER))thrownewError("Number too big");returnNumber(A)},toArray:function(A,I){constg=[];letQ=BigInt(A);for(I=BigInt(I);Q;)g.unshift(Number(Q%I)),Q/=I;returng},add:function(A,I){returnBigInt(A)+BigInt(I)},sub:function(A,I){returnBigInt(A)-BigInt(I)},neg:function(A){return-BigInt(A)},mul:function(A,I){returnBigInt(A)*BigInt(I)},square:function(A){returnBigInt(A)*BigInt(A)},pow:function(A,I){returnBigInt(A)**BigInt(I)},exp:function(A,I){returnBigInt(A)**BigInt(I)},abs:function(A){returnBigInt(A)>=0?BigInt(A):-BigInt(A)},div:function(A,I){returnBigInt(A)/BigInt(I)},mod:function(A,I){returnBigInt(A)%BigInt(I)},eq:function(A,I){returnBigInt(A)==BigInt(I)},neq:function(A,I){returnBigInt(A)!=BigInt(I)},lt:function(A,I){returnBigInt(A)<BigInt(I)},gt:function(A,I){returnBigInt(A)>BigInt(I)},leq:function(A,I){returnBigInt(A)<=BigInt(I)},geq:function(A,I){returnBigInt(A)>=BigInt(I)},band:function(A,I){returnBigInt(A)&BigInt(I)},bor:function(A,I){returnBigInt(A)|BigInt(I)},bxor:function(A,I){returnBigInt(A)^BigInt(I)},land:function(A,I){returnBigInt(A)&&BigInt(I)},lor:function(A,I){returnBigInt(A)||BigInt(I)},lnot:function(A){return!BigInt(A)}});functionh(A,I){returnA(I={exports:{}},I.exports),I.exports}varn=h((function(A){varI=function(A){varg=1e7,Q=9007199254740992,C=e(Q),B="function"==typeofBigInt;functionE(A,I,g,Q){returnvoid0===A?E[0]:void0!==I&&(10!=+I||g)?P(A,I,g,Q):j(A)}functioni(A,I){this.value=A,this.sign=I,this.isSmall=!1}functiont(A){this.value=A,this.sign=A<0,this.isSmall=!0}functionh(A){this.value=A}functionn(A){return-Q<A&&A<Q}functione(A){returnA<1e7?[A]:A<1e14?[A%1e7,Math.floor(A/1e7)]:[A%1e7,Math.floor(A/1e7)%1e7,Math.floor(A/1e14)]}functionD(A){o(A);varI=A.length;if(I<4&&l(A,C)<0)switch(I){case0:return0;case1:returnA[0];case2:returnA[0]+A[1]*g;default:returnA[0]+(A[1]+A[2]*g)*g}returnA}functiono(A){for(varI=A.length;0===A[--I];);A.length=I+1}functionw(A){for(varI=newArray(A),g=-1;++g<A;)I[g]=0;returnI}functionf(A){returnA>0?Math.floor(A):Math.ceil(A)}functionr(A,I){varQ,C,B=A.length,E=I.length,i=newArray(B),t=0,h=g;for(C=0;C<E;C++)t=(Q=A[C]+I[C]+t)>=h?1:0,i[C]=Q-t*h;for(;C<B;)t=(Q=A[C]+t)===h?1:0,i[C++]=Q-t*h;returnt>0&&i.push(t),i}functions(A,I){returnA.length>=I.length?r(A,I):r(I,A)}functiona(A,I){varQ,C,B=A.length,E=newArray(B),i=g;for(C=0;C<B;C++)Q=A[C]-i+I,I=Math.floor(Q/i),E[C]=Q-I*i,I+=1;for(;I>0;)E[C++]=I%i,I=Math.floor(I/i);returnE}functiony(A,I){varg,Q,C=A.length,B=I.length,E=newArray(C),i=0;for(g=0;g<B;g++)(Q=A[g]-i-I[g])<0?(Q+=1e7,i=1):i=0,E[g]=Q;for(g=B;g<C;g++){if(!((Q=A[g]-i)<0)){E[g++]=Q;break}Q+=1e7,E[g]=Q}for(;g<C;g++)E[g]=A[g];returno(E),E}functionM(A,I,g){varQ,C,B=A.length,E=newArray(B),h=-I;for(Q=0;Q<B;Q++)C=A[Q]+h,h=Math.floor(C/1e7),C%=1e7,E[Q]=C<0?C+1e7:C;return"number"==typeof(E=D(E))?(g&&(E=-E),newt(E)):newi(E,g)}functionF(A,I){varg,Q,C,B,E=A.length,i=I.length,t=w(E+i);for(C=0;C<E;++C){B=A[C];for(varh=0;h<i;++h)g=B*I[h]+t[C+h],Q=Math.floor(g/1e7),t[C+h]=g-1e7*Q,t[C+h+1]+=Q}returno(t),t}functionc(A,I){varQ,C,B=A.length,E=newArray(B),i=g,t=0;for(C=0;C<B