@widolabs/collateral-swap-sdk
Version:
TypeScript SDK for interacting with the Wido protocol to allow collateral swaps on Compound Comet.
1 lines • 642 kB
JavaScript
(function(Vt,Y){typeof exports=="object"&&typeof module!="undefined"?Y(exports):typeof define=="function"&&define.amd?define(["exports"],Y):(Vt=typeof globalThis!="undefined"?globalThis:Vt||self,Y(Vt["wido-compound-sdk"]={}))})(this,function(Vt){"use strict";var v1=Object.defineProperty;var w1=(Vt,Y,xe)=>Y in Vt?v1(Vt,Y,{enumerable:!0,configurable:!0,writable:!0,value:xe}):Vt[Y]=xe;var xr=(Vt,Y,xe)=>(w1(Vt,typeof Y!="symbol"?Y+"":Y,xe),xe);var Y=typeof globalThis!="undefined"?globalThis:typeof window!="undefined"?window:typeof global!="undefined"?global:typeof self!="undefined"?self:{};function xe(r){if(r.__esModule)return r;var e=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(r).forEach(function(t){var n=Object.getOwnPropertyDescriptor(r,t);Object.defineProperty(e,t,n.get?n:{enumerable:!0,get:function(){return r[t]}})}),e}var _u={exports:{}};(function(r){(function(e,t){function n(A,l){if(!A)throw new Error(l||"Assertion failed")}function i(A,l){A.super_=l;var y=function(){};y.prototype=l.prototype,A.prototype=new y,A.prototype.constructor=A}function a(A,l,y){if(a.isBN(A))return A;this.negative=0,this.words=null,this.length=0,this.red=null,A!==null&&((l==="le"||l==="be")&&(y=l,l=10),this._init(A||0,l||10,y||"be"))}typeof e=="object"?e.exports=a:t.BN=a,a.BN=a,a.wordSize=26;var s;try{typeof window!="undefined"&&typeof window.Buffer!="undefined"?s=window.Buffer:s=require("buffer").Buffer}catch{}a.isBN=function(l){return l instanceof a?!0:l!==null&&typeof l=="object"&&l.constructor.wordSize===a.wordSize&&Array.isArray(l.words)},a.max=function(l,y){return l.cmp(y)>0?l:y},a.min=function(l,y){return l.cmp(y)<0?l:y},a.prototype._init=function(l,y,b){if(typeof l=="number")return this._initNumber(l,y,b);if(typeof l=="object")return this._initArray(l,y,b);y==="hex"&&(y=16),n(y===(y|0)&&y>=2&&y<=36),l=l.toString().replace(/\s+/g,"");var w=0;l[0]==="-"&&(w++,this.negative=1),w<l.length&&(y===16?this._parseHex(l,w,b):(this._parseBase(l,y,w),b==="le"&&this._initArray(this.toArray(),y,b)))},a.prototype._initNumber=function(l,y,b){l<0&&(this.negative=1,l=-l),l<67108864?(this.words=[l&67108863],this.length=1):l<4503599627370496?(this.words=[l&67108863,l/67108864&67108863],this.length=2):(n(l<9007199254740992),this.words=[l&67108863,l/67108864&67108863,1],this.length=3),b==="le"&&this._initArray(this.toArray(),y,b)},a.prototype._initArray=function(l,y,b){if(n(typeof l.length=="number"),l.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(l.length/3),this.words=new Array(this.length);for(var w=0;w<this.length;w++)this.words[w]=0;var E,M,I=0;if(b==="be")for(w=l.length-1,E=0;w>=0;w-=3)M=l[w]|l[w-1]<<8|l[w-2]<<16,this.words[E]|=M<<I&67108863,this.words[E+1]=M>>>26-I&67108863,I+=24,I>=26&&(I-=26,E++);else if(b==="le")for(w=0,E=0;w<l.length;w+=3)M=l[w]|l[w+1]<<8|l[w+2]<<16,this.words[E]|=M<<I&67108863,this.words[E+1]=M>>>26-I&67108863,I+=24,I>=26&&(I-=26,E++);return this._strip()};function o(A,l){var y=A.charCodeAt(l);if(y>=48&&y<=57)return y-48;if(y>=65&&y<=70)return y-55;if(y>=97&&y<=102)return y-87;n(!1,"Invalid character in "+A)}function c(A,l,y){var b=o(A,y);return y-1>=l&&(b|=o(A,y-1)<<4),b}a.prototype._parseHex=function(l,y,b){this.length=Math.ceil((l.length-y)/6),this.words=new Array(this.length);for(var w=0;w<this.length;w++)this.words[w]=0;var E=0,M=0,I;if(b==="be")for(w=l.length-1;w>=y;w-=2)I=c(l,y,w)<<E,this.words[M]|=I&67108863,E>=18?(E-=18,M+=1,this.words[M]|=I>>>26):E+=8;else{var m=l.length-y;for(w=m%2===0?y+1:y;w<l.length;w+=2)I=c(l,y,w)<<E,this.words[M]|=I&67108863,E>=18?(E-=18,M+=1,this.words[M]|=I>>>26):E+=8}this._strip()};function u(A,l,y,b){for(var w=0,E=0,M=Math.min(A.length,y),I=l;I<M;I++){var m=A.charCodeAt(I)-48;w*=b,m>=49?E=m-49+10:m>=17?E=m-17+10:E=m,n(m>=0&&E<b,"Invalid character"),w+=E}return w}a.prototype._parseBase=function(l,y,b){this.words=[0],this.length=1;for(var w=0,E=1;E<=67108863;E*=y)w++;w--,E=E/y|0;for(var M=l.length-b,I=M%w,m=Math.min(M,M-I)+b,f=0,x=b;x<m;x+=w)f=u(l,x,x+w,y),this.imuln(E),this.words[0]+f<67108864?this.words[0]+=f:this._iaddn(f);if(I!==0){var B=1;for(f=u(l,x,l.length,y),x=0;x<I;x++)B*=y;this.imuln(B),this.words[0]+f<67108864?this.words[0]+=f:this._iaddn(f)}this._strip()},a.prototype.copy=function(l){l.words=new Array(this.length);for(var y=0;y<this.length;y++)l.words[y]=this.words[y];l.length=this.length,l.negative=this.negative,l.red=this.red};function d(A,l){A.words=l.words,A.length=l.length,A.negative=l.negative,A.red=l.red}if(a.prototype._move=function(l){d(l,this)},a.prototype.clone=function(){var l=new a(null);return this.copy(l),l},a.prototype._expand=function(l){for(;this.length<l;)this.words[this.length++]=0;return this},a.prototype._strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},a.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},typeof Symbol!="undefined"&&typeof Symbol.for=="function")try{a.prototype[Symbol.for("nodejs.util.inspect.custom")]=h}catch{a.prototype.inspect=h}else a.prototype.inspect=h;function h(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"}var v=["","0","00","000","0000","00000","000000","0000000","00000000","000000000","0000000000","00000000000","000000000000","0000000000000","00000000000000","000000000000000","0000000000000000","00000000000000000","000000000000000000","0000000000000000000","00000000000000000000","000000000000000000000","0000000000000000000000","00000000000000000000000","000000000000000000000000","0000000000000000000000000"],g=[0,0,25,16,12,11,10,9,8,8,7,7,7,7,6,6,6,6,6,6,6,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5,5],C=[0,0,33554432,43046721,16777216,48828125,60466176,40353607,16777216,43046721,1e7,19487171,35831808,62748517,7529536,11390625,16777216,24137569,34012224,47045881,64e6,4084101,5153632,6436343,7962624,9765625,11881376,14348907,17210368,20511149,243e5,28629151,33554432,39135393,45435424,52521875,60466176];a.prototype.toString=function(l,y){l=l||10,y=y|0||1;var b;if(l===16||l==="hex"){b="";for(var w=0,E=0,M=0;M<this.length;M++){var I=this.words[M],m=((I<<w|E)&16777215).toString(16);E=I>>>24-w&16777215,w+=2,w>=26&&(w-=26,M--),E!==0||M!==this.length-1?b=v[6-m.length]+m+b:b=m+b}for(E!==0&&(b=E.toString(16)+b);b.length%y!==0;)b="0"+b;return this.negative!==0&&(b="-"+b),b}if(l===(l|0)&&l>=2&&l<=36){var f=g[l],x=C[l];b="";var B=this.clone();for(B.negative=0;!B.isZero();){var p=B.modrn(x).toString(l);B=B.idivn(x),B.isZero()?b=p+b:b=v[f-p.length]+p+b}for(this.isZero()&&(b="0"+b);b.length%y!==0;)b="0"+b;return this.negative!==0&&(b="-"+b),b}n(!1,"Base should be between 2 and 36")},a.prototype.toNumber=function(){var l=this.words[0];return this.length===2?l+=this.words[1]*67108864:this.length===3&&this.words[2]===1?l+=4503599627370496+this.words[1]*67108864:this.length>2&&n(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-l:l},a.prototype.toJSON=function(){return this.toString(16,2)},s&&(a.prototype.toBuffer=function(l,y){return this.toArrayLike(s,l,y)}),a.prototype.toArray=function(l,y){return this.toArrayLike(Array,l,y)};var S=function(l,y){return l.allocUnsafe?l.allocUnsafe(y):new l(y)};a.prototype.toArrayLike=function(l,y,b){this._strip();var w=this.byteLength(),E=b||Math.max(1,w);n(w<=E,"byte array longer than desired length"),n(E>0,"Requested array length <= 0");var M=S(l,E),I=y==="le"?"LE":"BE";return this["_toArrayLike"+I](M,w),M},a.prototype._toArrayLikeLE=function(l,y){for(var b=0,w=0,E=0,M=0;E<this.length;E++){var I=this.words[E]<<M|w;l[b++]=I&255,b<l.length&&(l[b++]=I>>8&255),b<l.length&&(l[b++]=I>>16&255),M===6?(b<l.length&&(l[b++]=I>>24&255),w=0,M=0):(w=I>>>24,M+=2)}if(b<l.length)for(l[b++]=w;b<l.length;)l[b++]=0},a.prototype._toArrayLikeBE=function(l,y){for(var b=l.length-1,w=0,E=0,M=0;E<this.length;E++){var I=this.words[E]<<M|w;l[b--]=I&255,b>=0&&(l[b--]=I>>8&255),b>=0&&(l[b--]=I>>16&255),M===6?(b>=0&&(l[b--]=I>>24&255),w=0,M=0):(w=I>>>24,M+=2)}if(b>=0)for(l[b--]=w;b>=0;)l[b--]=0},Math.clz32?a.prototype._countBits=function(l){return 32-Math.clz32(l)}:a.prototype._countBits=function(l){var y=l,b=0;return y>=4096&&(b+=13,y>>>=13),y>=64&&(b+=7,y>>>=7),y>=8&&(b+=4,y>>>=4),y>=2&&(b+=2,y>>>=2),b+y},a.prototype._zeroBits=function(l){if(l===0)return 26;var y=l,b=0;return(y&8191)===0&&(b+=13,y>>>=13),(y&127)===0&&(b+=7,y>>>=7),(y&15)===0&&(b+=4,y>>>=4),(y&3)===0&&(b+=2,y>>>=2),(y&1)===0&&b++,b},a.prototype.bitLength=function(){var l=this.words[this.length-1],y=this._countBits(l);return(this.length-1)*26+y};function T(A){for(var l=new Array(A.bitLength()),y=0;y<l.length;y++){var b=y/26|0,w=y%26;l[y]=A.words[b]>>>w&1}return l}a.prototype.zeroBits=function(){if(this.isZero())return 0;for(var l=0,y=0;y<this.length;y++){var b=this._zeroBits(this.words[y]);if(l+=b,b!==26)break}return l},a.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},a.prototype.toTwos=function(l){return this.negative!==0?this.abs().inotn(l).iaddn(1):this.clone()},a.prototype.fromTwos=function(l){return this.testn(l-1)?this.notn(l).iaddn(1).ineg():this.clone()},a.prototype.isNeg=function(){return this.negative!==0},a.prototype.neg=function(){return this.clone().ineg()},a.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},a.prototype.iuor=function(l){for(;this.length<l.length;)this.words[this.length++]=0;for(var y=0;y<l.length;y++)this.words[y]=this.words[y]|l.words[y];return this._strip()},a.prototype.ior=function(l){return n((this.negative|l.negative)===0),this.iuor(l)},a.prototype.or=function(l){return this.length>l.length?this.clone().ior(l):l.clone().ior(this)},a.prototype.uor=function(l){return this.length>l.length?this.clone().iuor(l):l.clone().iuor(this)},a.prototype.iuand=function(l){var y;this.length>l.length?y=l:y=this;for(var b=0;b<y.length;b++)this.words[b]=this.words[b]&l.words[b];return this.length=y.length,this._strip()},a.prototype.iand=function(l){return n((this.negative|l.negative)===0),this.iuand(l)},a.prototype.and=function(l){return this.length>l.length?this.clone().iand(l):l.clone().iand(this)},a.prototype.uand=function(l){return this.length>l.length?this.clone().iuand(l):l.clone().iuand(this)},a.prototype.iuxor=function(l){var y,b;this.length>l.length?(y=this,b=l):(y=l,b=this);for(var w=0;w<b.length;w++)this.words[w]=y.words[w]^b.words[w];if(this!==y)for(;w<y.length;w++)this.words[w]=y.words[w];return this.length=y.length,this._strip()},a.prototype.ixor=function(l){return n((this.negative|l.negative)===0),this.iuxor(l)},a.prototype.xor=function(l){return this.length>l.length?this.clone().ixor(l):l.clone().ixor(this)},a.prototype.uxor=function(l){return this.length>l.length?this.clone().iuxor(l):l.clone().iuxor(this)},a.prototype.inotn=function(l){n(typeof l=="number"&&l>=0);var y=Math.ceil(l/26)|0,b=l%26;this._expand(y),b>0&&y--;for(var w=0;w<y;w++)this.words[w]=~this.words[w]&67108863;return b>0&&(this.words[w]=~this.words[w]&67108863>>26-b),this._strip()},a.prototype.notn=function(l){return this.clone().inotn(l)},a.prototype.setn=function(l,y){n(typeof l=="number"&&l>=0);var b=l/26|0,w=l%26;return this._expand(b+1),y?this.words[b]=this.words[b]|1<<w:this.words[b]=this.words[b]&~(1<<w),this._strip()},a.prototype.iadd=function(l){var y;if(this.negative!==0&&l.negative===0)return this.negative=0,y=this.isub(l),this.negative^=1,this._normSign();if(this.negative===0&&l.negative!==0)return l.negative=0,y=this.isub(l),l.negative=1,y._normSign();var b,w;this.length>l.length?(b=this,w=l):(b=l,w=this);for(var E=0,M=0;M<w.length;M++)y=(b.words[M]|0)+(w.words[M]|0)+E,this.words[M]=y&67108863,E=y>>>26;for(;E!==0&&M<b.length;M++)y=(b.words[M]|0)+E,this.words[M]=y&67108863,E=y>>>26;if(this.length=b.length,E!==0)this.words[this.length]=E,this.length++;else if(b!==this)for(;M<b.length;M++)this.words[M]=b.words[M];return this},a.prototype.add=function(l){var y;return l.negative!==0&&this.negative===0?(l.negative=0,y=this.sub(l),l.negative^=1,y):l.negative===0&&this.negative!==0?(this.negative=0,y=l.sub(this),this.negative=1,y):this.length>l.length?this.clone().iadd(l):l.clone().iadd(this)},a.prototype.isub=function(l){if(l.negative!==0){l.negative=0;var y=this.iadd(l);return l.negative=1,y._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(l),this.negative=1,this._normSign();var b=this.cmp(l);if(b===0)return this.negative=0,this.length=1,this.words[0]=0,this;var w,E;b>0?(w=this,E=l):(w=l,E=this);for(var M=0,I=0;I<E.length;I++)y=(w.words[I]|0)-(E.words[I]|0)+M,M=y>>26,this.words[I]=y&67108863;for(;M!==0&&I<w.length;I++)y=(w.words[I]|0)+M,M=y>>26,this.words[I]=y&67108863;if(M===0&&I<w.length&&w!==this)for(;I<w.length;I++)this.words[I]=w.words[I];return this.length=Math.max(this.length,I),w!==this&&(this.negative=1),this._strip()},a.prototype.sub=function(l){return this.clone().isub(l)};function k(A,l,y){y.negative=l.negative^A.negative;var b=A.length+l.length|0;y.length=b,b=b-1|0;var w=A.words[0]|0,E=l.words[0]|0,M=w*E,I=M&67108863,m=M/67108864|0;y.words[0]=I;for(var f=1;f<b;f++){for(var x=m>>>26,B=m&67108863,p=Math.min(f,l.length-1),P=Math.max(0,f-A.length+1);P<=p;P++){var O=f-P|0;w=A.words[O]|0,E=l.words[P]|0,M=w*E+B,x+=M/67108864|0,B=M&67108863}y.words[f]=B|0,m=x|0}return m!==0?y.words[f]=m|0:y.length--,y._strip()}var D=function(l,y,b){var w=l.words,E=y.words,M=b.words,I=0,m,f,x,B=w[0]|0,p=B&8191,P=B>>>13,O=w[1]|0,R=O&8191,U=O>>>13,J=w[2]|0,W=J&8191,K=J>>>13,ut=w[3]|0,Q=ut&8191,oe=ut>>>13,Gn=w[4]|0,Se=Gn&8191,Me=Gn>>>13,jn=w[5]|0,Pe=jn&8191,ke=jn>>>13,qn=w[6]|0,Be=qn&8191,Ie=qn>>>13,Hn=w[7]|0,Ne=Hn&8191,Re=Hn>>>13,zn=w[8]|0,Oe=zn&8191,Fe=zn>>>13,Wn=w[9]|0,De=Wn&8191,Ue=Wn>>>13,Kn=E[0]|0,Le=Kn&8191,Ge=Kn>>>13,Vn=E[1]|0,je=Vn&8191,qe=Vn>>>13,$n=E[2]|0,He=$n&8191,ze=$n>>>13,Jn=E[3]|0,We=Jn&8191,Ke=Jn>>>13,Yn=E[4]|0,Ve=Yn&8191,$e=Yn>>>13,Qn=E[5]|0,Je=Qn&8191,Ye=Qn>>>13,Xn=E[6]|0,Qe=Xn&8191,Xe=Xn>>>13,Zn=E[7]|0,Ze=Zn&8191,et=Zn>>>13,ei=E[8]|0,tt=ei&8191,rt=ei>>>13,ti=E[9]|0,nt=ti&8191,it=ti>>>13;b.negative=l.negative^y.negative,b.length=19,m=Math.imul(p,Le),f=Math.imul(p,Ge),f=f+Math.imul(P,Le)|0,x=Math.imul(P,Ge);var xn=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(xn>>>26)|0,xn&=67108863,m=Math.imul(R,Le),f=Math.imul(R,Ge),f=f+Math.imul(U,Le)|0,x=Math.imul(U,Ge),m=m+Math.imul(p,je)|0,f=f+Math.imul(p,qe)|0,f=f+Math.imul(P,je)|0,x=x+Math.imul(P,qe)|0;var gn=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(gn>>>26)|0,gn&=67108863,m=Math.imul(W,Le),f=Math.imul(W,Ge),f=f+Math.imul(K,Le)|0,x=Math.imul(K,Ge),m=m+Math.imul(R,je)|0,f=f+Math.imul(R,qe)|0,f=f+Math.imul(U,je)|0,x=x+Math.imul(U,qe)|0,m=m+Math.imul(p,He)|0,f=f+Math.imul(p,ze)|0,f=f+Math.imul(P,He)|0,x=x+Math.imul(P,ze)|0;var vn=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(vn>>>26)|0,vn&=67108863,m=Math.imul(Q,Le),f=Math.imul(Q,Ge),f=f+Math.imul(oe,Le)|0,x=Math.imul(oe,Ge),m=m+Math.imul(W,je)|0,f=f+Math.imul(W,qe)|0,f=f+Math.imul(K,je)|0,x=x+Math.imul(K,qe)|0,m=m+Math.imul(R,He)|0,f=f+Math.imul(R,ze)|0,f=f+Math.imul(U,He)|0,x=x+Math.imul(U,ze)|0,m=m+Math.imul(p,We)|0,f=f+Math.imul(p,Ke)|0,f=f+Math.imul(P,We)|0,x=x+Math.imul(P,Ke)|0;var wn=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(wn>>>26)|0,wn&=67108863,m=Math.imul(Se,Le),f=Math.imul(Se,Ge),f=f+Math.imul(Me,Le)|0,x=Math.imul(Me,Ge),m=m+Math.imul(Q,je)|0,f=f+Math.imul(Q,qe)|0,f=f+Math.imul(oe,je)|0,x=x+Math.imul(oe,qe)|0,m=m+Math.imul(W,He)|0,f=f+Math.imul(W,ze)|0,f=f+Math.imul(K,He)|0,x=x+Math.imul(K,ze)|0,m=m+Math.imul(R,We)|0,f=f+Math.imul(R,Ke)|0,f=f+Math.imul(U,We)|0,x=x+Math.imul(U,Ke)|0,m=m+Math.imul(p,Ve)|0,f=f+Math.imul(p,$e)|0,f=f+Math.imul(P,Ve)|0,x=x+Math.imul(P,$e)|0;var An=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(An>>>26)|0,An&=67108863,m=Math.imul(Pe,Le),f=Math.imul(Pe,Ge),f=f+Math.imul(ke,Le)|0,x=Math.imul(ke,Ge),m=m+Math.imul(Se,je)|0,f=f+Math.imul(Se,qe)|0,f=f+Math.imul(Me,je)|0,x=x+Math.imul(Me,qe)|0,m=m+Math.imul(Q,He)|0,f=f+Math.imul(Q,ze)|0,f=f+Math.imul(oe,He)|0,x=x+Math.imul(oe,ze)|0,m=m+Math.imul(W,We)|0,f=f+Math.imul(W,Ke)|0,f=f+Math.imul(K,We)|0,x=x+Math.imul(K,Ke)|0,m=m+Math.imul(R,Ve)|0,f=f+Math.imul(R,$e)|0,f=f+Math.imul(U,Ve)|0,x=x+Math.imul(U,$e)|0,m=m+Math.imul(p,Je)|0,f=f+Math.imul(p,Ye)|0,f=f+Math.imul(P,Je)|0,x=x+Math.imul(P,Ye)|0;var fu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(fu>>>26)|0,fu&=67108863,m=Math.imul(Be,Le),f=Math.imul(Be,Ge),f=f+Math.imul(Ie,Le)|0,x=Math.imul(Ie,Ge),m=m+Math.imul(Pe,je)|0,f=f+Math.imul(Pe,qe)|0,f=f+Math.imul(ke,je)|0,x=x+Math.imul(ke,qe)|0,m=m+Math.imul(Se,He)|0,f=f+Math.imul(Se,ze)|0,f=f+Math.imul(Me,He)|0,x=x+Math.imul(Me,ze)|0,m=m+Math.imul(Q,We)|0,f=f+Math.imul(Q,Ke)|0,f=f+Math.imul(oe,We)|0,x=x+Math.imul(oe,Ke)|0,m=m+Math.imul(W,Ve)|0,f=f+Math.imul(W,$e)|0,f=f+Math.imul(K,Ve)|0,x=x+Math.imul(K,$e)|0,m=m+Math.imul(R,Je)|0,f=f+Math.imul(R,Ye)|0,f=f+Math.imul(U,Je)|0,x=x+Math.imul(U,Ye)|0,m=m+Math.imul(p,Qe)|0,f=f+Math.imul(p,Xe)|0,f=f+Math.imul(P,Qe)|0,x=x+Math.imul(P,Xe)|0;var du=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(du>>>26)|0,du&=67108863,m=Math.imul(Ne,Le),f=Math.imul(Ne,Ge),f=f+Math.imul(Re,Le)|0,x=Math.imul(Re,Ge),m=m+Math.imul(Be,je)|0,f=f+Math.imul(Be,qe)|0,f=f+Math.imul(Ie,je)|0,x=x+Math.imul(Ie,qe)|0,m=m+Math.imul(Pe,He)|0,f=f+Math.imul(Pe,ze)|0,f=f+Math.imul(ke,He)|0,x=x+Math.imul(ke,ze)|0,m=m+Math.imul(Se,We)|0,f=f+Math.imul(Se,Ke)|0,f=f+Math.imul(Me,We)|0,x=x+Math.imul(Me,Ke)|0,m=m+Math.imul(Q,Ve)|0,f=f+Math.imul(Q,$e)|0,f=f+Math.imul(oe,Ve)|0,x=x+Math.imul(oe,$e)|0,m=m+Math.imul(W,Je)|0,f=f+Math.imul(W,Ye)|0,f=f+Math.imul(K,Je)|0,x=x+Math.imul(K,Ye)|0,m=m+Math.imul(R,Qe)|0,f=f+Math.imul(R,Xe)|0,f=f+Math.imul(U,Qe)|0,x=x+Math.imul(U,Xe)|0,m=m+Math.imul(p,Ze)|0,f=f+Math.imul(p,et)|0,f=f+Math.imul(P,Ze)|0,x=x+Math.imul(P,et)|0;var pu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(pu>>>26)|0,pu&=67108863,m=Math.imul(Oe,Le),f=Math.imul(Oe,Ge),f=f+Math.imul(Fe,Le)|0,x=Math.imul(Fe,Ge),m=m+Math.imul(Ne,je)|0,f=f+Math.imul(Ne,qe)|0,f=f+Math.imul(Re,je)|0,x=x+Math.imul(Re,qe)|0,m=m+Math.imul(Be,He)|0,f=f+Math.imul(Be,ze)|0,f=f+Math.imul(Ie,He)|0,x=x+Math.imul(Ie,ze)|0,m=m+Math.imul(Pe,We)|0,f=f+Math.imul(Pe,Ke)|0,f=f+Math.imul(ke,We)|0,x=x+Math.imul(ke,Ke)|0,m=m+Math.imul(Se,Ve)|0,f=f+Math.imul(Se,$e)|0,f=f+Math.imul(Me,Ve)|0,x=x+Math.imul(Me,$e)|0,m=m+Math.imul(Q,Je)|0,f=f+Math.imul(Q,Ye)|0,f=f+Math.imul(oe,Je)|0,x=x+Math.imul(oe,Ye)|0,m=m+Math.imul(W,Qe)|0,f=f+Math.imul(W,Xe)|0,f=f+Math.imul(K,Qe)|0,x=x+Math.imul(K,Xe)|0,m=m+Math.imul(R,Ze)|0,f=f+Math.imul(R,et)|0,f=f+Math.imul(U,Ze)|0,x=x+Math.imul(U,et)|0,m=m+Math.imul(p,tt)|0,f=f+Math.imul(p,rt)|0,f=f+Math.imul(P,tt)|0,x=x+Math.imul(P,rt)|0;var hu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(hu>>>26)|0,hu&=67108863,m=Math.imul(De,Le),f=Math.imul(De,Ge),f=f+Math.imul(Ue,Le)|0,x=Math.imul(Ue,Ge),m=m+Math.imul(Oe,je)|0,f=f+Math.imul(Oe,qe)|0,f=f+Math.imul(Fe,je)|0,x=x+Math.imul(Fe,qe)|0,m=m+Math.imul(Ne,He)|0,f=f+Math.imul(Ne,ze)|0,f=f+Math.imul(Re,He)|0,x=x+Math.imul(Re,ze)|0,m=m+Math.imul(Be,We)|0,f=f+Math.imul(Be,Ke)|0,f=f+Math.imul(Ie,We)|0,x=x+Math.imul(Ie,Ke)|0,m=m+Math.imul(Pe,Ve)|0,f=f+Math.imul(Pe,$e)|0,f=f+Math.imul(ke,Ve)|0,x=x+Math.imul(ke,$e)|0,m=m+Math.imul(Se,Je)|0,f=f+Math.imul(Se,Ye)|0,f=f+Math.imul(Me,Je)|0,x=x+Math.imul(Me,Ye)|0,m=m+Math.imul(Q,Qe)|0,f=f+Math.imul(Q,Xe)|0,f=f+Math.imul(oe,Qe)|0,x=x+Math.imul(oe,Xe)|0,m=m+Math.imul(W,Ze)|0,f=f+Math.imul(W,et)|0,f=f+Math.imul(K,Ze)|0,x=x+Math.imul(K,et)|0,m=m+Math.imul(R,tt)|0,f=f+Math.imul(R,rt)|0,f=f+Math.imul(U,tt)|0,x=x+Math.imul(U,rt)|0,m=m+Math.imul(p,nt)|0,f=f+Math.imul(p,it)|0,f=f+Math.imul(P,nt)|0,x=x+Math.imul(P,it)|0;var yu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(yu>>>26)|0,yu&=67108863,m=Math.imul(De,je),f=Math.imul(De,qe),f=f+Math.imul(Ue,je)|0,x=Math.imul(Ue,qe),m=m+Math.imul(Oe,He)|0,f=f+Math.imul(Oe,ze)|0,f=f+Math.imul(Fe,He)|0,x=x+Math.imul(Fe,ze)|0,m=m+Math.imul(Ne,We)|0,f=f+Math.imul(Ne,Ke)|0,f=f+Math.imul(Re,We)|0,x=x+Math.imul(Re,Ke)|0,m=m+Math.imul(Be,Ve)|0,f=f+Math.imul(Be,$e)|0,f=f+Math.imul(Ie,Ve)|0,x=x+Math.imul(Ie,$e)|0,m=m+Math.imul(Pe,Je)|0,f=f+Math.imul(Pe,Ye)|0,f=f+Math.imul(ke,Je)|0,x=x+Math.imul(ke,Ye)|0,m=m+Math.imul(Se,Qe)|0,f=f+Math.imul(Se,Xe)|0,f=f+Math.imul(Me,Qe)|0,x=x+Math.imul(Me,Xe)|0,m=m+Math.imul(Q,Ze)|0,f=f+Math.imul(Q,et)|0,f=f+Math.imul(oe,Ze)|0,x=x+Math.imul(oe,et)|0,m=m+Math.imul(W,tt)|0,f=f+Math.imul(W,rt)|0,f=f+Math.imul(K,tt)|0,x=x+Math.imul(K,rt)|0,m=m+Math.imul(R,nt)|0,f=f+Math.imul(R,it)|0,f=f+Math.imul(U,nt)|0,x=x+Math.imul(U,it)|0;var mu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(mu>>>26)|0,mu&=67108863,m=Math.imul(De,He),f=Math.imul(De,ze),f=f+Math.imul(Ue,He)|0,x=Math.imul(Ue,ze),m=m+Math.imul(Oe,We)|0,f=f+Math.imul(Oe,Ke)|0,f=f+Math.imul(Fe,We)|0,x=x+Math.imul(Fe,Ke)|0,m=m+Math.imul(Ne,Ve)|0,f=f+Math.imul(Ne,$e)|0,f=f+Math.imul(Re,Ve)|0,x=x+Math.imul(Re,$e)|0,m=m+Math.imul(Be,Je)|0,f=f+Math.imul(Be,Ye)|0,f=f+Math.imul(Ie,Je)|0,x=x+Math.imul(Ie,Ye)|0,m=m+Math.imul(Pe,Qe)|0,f=f+Math.imul(Pe,Xe)|0,f=f+Math.imul(ke,Qe)|0,x=x+Math.imul(ke,Xe)|0,m=m+Math.imul(Se,Ze)|0,f=f+Math.imul(Se,et)|0,f=f+Math.imul(Me,Ze)|0,x=x+Math.imul(Me,et)|0,m=m+Math.imul(Q,tt)|0,f=f+Math.imul(Q,rt)|0,f=f+Math.imul(oe,tt)|0,x=x+Math.imul(oe,rt)|0,m=m+Math.imul(W,nt)|0,f=f+Math.imul(W,it)|0,f=f+Math.imul(K,nt)|0,x=x+Math.imul(K,it)|0;var bu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(bu>>>26)|0,bu&=67108863,m=Math.imul(De,We),f=Math.imul(De,Ke),f=f+Math.imul(Ue,We)|0,x=Math.imul(Ue,Ke),m=m+Math.imul(Oe,Ve)|0,f=f+Math.imul(Oe,$e)|0,f=f+Math.imul(Fe,Ve)|0,x=x+Math.imul(Fe,$e)|0,m=m+Math.imul(Ne,Je)|0,f=f+Math.imul(Ne,Ye)|0,f=f+Math.imul(Re,Je)|0,x=x+Math.imul(Re,Ye)|0,m=m+Math.imul(Be,Qe)|0,f=f+Math.imul(Be,Xe)|0,f=f+Math.imul(Ie,Qe)|0,x=x+Math.imul(Ie,Xe)|0,m=m+Math.imul(Pe,Ze)|0,f=f+Math.imul(Pe,et)|0,f=f+Math.imul(ke,Ze)|0,x=x+Math.imul(ke,et)|0,m=m+Math.imul(Se,tt)|0,f=f+Math.imul(Se,rt)|0,f=f+Math.imul(Me,tt)|0,x=x+Math.imul(Me,rt)|0,m=m+Math.imul(Q,nt)|0,f=f+Math.imul(Q,it)|0,f=f+Math.imul(oe,nt)|0,x=x+Math.imul(oe,it)|0;var xu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(xu>>>26)|0,xu&=67108863,m=Math.imul(De,Ve),f=Math.imul(De,$e),f=f+Math.imul(Ue,Ve)|0,x=Math.imul(Ue,$e),m=m+Math.imul(Oe,Je)|0,f=f+Math.imul(Oe,Ye)|0,f=f+Math.imul(Fe,Je)|0,x=x+Math.imul(Fe,Ye)|0,m=m+Math.imul(Ne,Qe)|0,f=f+Math.imul(Ne,Xe)|0,f=f+Math.imul(Re,Qe)|0,x=x+Math.imul(Re,Xe)|0,m=m+Math.imul(Be,Ze)|0,f=f+Math.imul(Be,et)|0,f=f+Math.imul(Ie,Ze)|0,x=x+Math.imul(Ie,et)|0,m=m+Math.imul(Pe,tt)|0,f=f+Math.imul(Pe,rt)|0,f=f+Math.imul(ke,tt)|0,x=x+Math.imul(ke,rt)|0,m=m+Math.imul(Se,nt)|0,f=f+Math.imul(Se,it)|0,f=f+Math.imul(Me,nt)|0,x=x+Math.imul(Me,it)|0;var gu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(gu>>>26)|0,gu&=67108863,m=Math.imul(De,Je),f=Math.imul(De,Ye),f=f+Math.imul(Ue,Je)|0,x=Math.imul(Ue,Ye),m=m+Math.imul(Oe,Qe)|0,f=f+Math.imul(Oe,Xe)|0,f=f+Math.imul(Fe,Qe)|0,x=x+Math.imul(Fe,Xe)|0,m=m+Math.imul(Ne,Ze)|0,f=f+Math.imul(Ne,et)|0,f=f+Math.imul(Re,Ze)|0,x=x+Math.imul(Re,et)|0,m=m+Math.imul(Be,tt)|0,f=f+Math.imul(Be,rt)|0,f=f+Math.imul(Ie,tt)|0,x=x+Math.imul(Ie,rt)|0,m=m+Math.imul(Pe,nt)|0,f=f+Math.imul(Pe,it)|0,f=f+Math.imul(ke,nt)|0,x=x+Math.imul(ke,it)|0;var vu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(vu>>>26)|0,vu&=67108863,m=Math.imul(De,Qe),f=Math.imul(De,Xe),f=f+Math.imul(Ue,Qe)|0,x=Math.imul(Ue,Xe),m=m+Math.imul(Oe,Ze)|0,f=f+Math.imul(Oe,et)|0,f=f+Math.imul(Fe,Ze)|0,x=x+Math.imul(Fe,et)|0,m=m+Math.imul(Ne,tt)|0,f=f+Math.imul(Ne,rt)|0,f=f+Math.imul(Re,tt)|0,x=x+Math.imul(Re,rt)|0,m=m+Math.imul(Be,nt)|0,f=f+Math.imul(Be,it)|0,f=f+Math.imul(Ie,nt)|0,x=x+Math.imul(Ie,it)|0;var wu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(wu>>>26)|0,wu&=67108863,m=Math.imul(De,Ze),f=Math.imul(De,et),f=f+Math.imul(Ue,Ze)|0,x=Math.imul(Ue,et),m=m+Math.imul(Oe,tt)|0,f=f+Math.imul(Oe,rt)|0,f=f+Math.imul(Fe,tt)|0,x=x+Math.imul(Fe,rt)|0,m=m+Math.imul(Ne,nt)|0,f=f+Math.imul(Ne,it)|0,f=f+Math.imul(Re,nt)|0,x=x+Math.imul(Re,it)|0;var Au=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(Au>>>26)|0,Au&=67108863,m=Math.imul(De,tt),f=Math.imul(De,rt),f=f+Math.imul(Ue,tt)|0,x=Math.imul(Ue,rt),m=m+Math.imul(Oe,nt)|0,f=f+Math.imul(Oe,it)|0,f=f+Math.imul(Fe,nt)|0,x=x+Math.imul(Fe,it)|0;var Eu=(I+m|0)+((f&8191)<<13)|0;I=(x+(f>>>13)|0)+(Eu>>>26)|0,Eu&=67108863,m=Math.imul(De,nt),f=Math.imul(De,it),f=f+Math.imul(Ue,nt)|0,x=Math.imul(Ue,it);var Tu=(I+m|0)+((f&8191)<<13)|0;return I=(x+(f>>>13)|0)+(Tu>>>26)|0,Tu&=67108863,M[0]=xn,M[1]=gn,M[2]=vn,M[3]=wn,M[4]=An,M[5]=fu,M[6]=du,M[7]=pu,M[8]=hu,M[9]=yu,M[10]=mu,M[11]=bu,M[12]=xu,M[13]=gu,M[14]=vu,M[15]=wu,M[16]=Au,M[17]=Eu,M[18]=Tu,I!==0&&(M[19]=I,b.length++),b};Math.imul||(D=k);function L(A,l,y){y.negative=l.negative^A.negative,y.length=A.length+l.length;for(var b=0,w=0,E=0;E<y.length-1;E++){var M=w;w=0;for(var I=b&67108863,m=Math.min(E,l.length-1),f=Math.max(0,E-A.length+1);f<=m;f++){var x=E-f,B=A.words[x]|0,p=l.words[f]|0,P=B*p,O=P&67108863;M=M+(P/67108864|0)|0,O=O+I|0,I=O&67108863,M=M+(O>>>26)|0,w+=M>>>26,M&=67108863}y.words[E]=I,b=M,M=w}return b!==0?y.words[E]=b:y.length--,y._strip()}function j(A,l,y){return L(A,l,y)}a.prototype.mulTo=function(l,y){var b,w=this.length+l.length;return this.length===10&&l.length===10?b=D(this,l,y):w<63?b=k(this,l,y):w<1024?b=L(this,l,y):b=j(this,l,y),b},a.prototype.mul=function(l){var y=new a(null);return y.words=new Array(this.length+l.length),this.mulTo(l,y)},a.prototype.mulf=function(l){var y=new a(null);return y.words=new Array(this.length+l.length),j(this,l,y)},a.prototype.imul=function(l){return this.clone().mulTo(l,this)},a.prototype.imuln=function(l){var y=l<0;y&&(l=-l),n(typeof l=="number"),n(l<67108864);for(var b=0,w=0;w<this.length;w++){var E=(this.words[w]|0)*l,M=(E&67108863)+(b&67108863);b>>=26,b+=E/67108864|0,b+=M>>>26,this.words[w]=M&67108863}return b!==0&&(this.words[w]=b,this.length++),y?this.ineg():this},a.prototype.muln=function(l){return this.clone().imuln(l)},a.prototype.sqr=function(){return this.mul(this)},a.prototype.isqr=function(){return this.imul(this.clone())},a.prototype.pow=function(l){var y=T(l);if(y.length===0)return new a(1);for(var b=this,w=0;w<y.length&&y[w]===0;w++,b=b.sqr());if(++w<y.length)for(var E=b.sqr();w<y.length;w++,E=E.sqr())y[w]!==0&&(b=b.mul(E));return b},a.prototype.iushln=function(l){n(typeof l=="number"&&l>=0);var y=l%26,b=(l-y)/26,w=67108863>>>26-y<<26-y,E;if(y!==0){var M=0;for(E=0;E<this.length;E++){var I=this.words[E]&w,m=(this.words[E]|0)-I<<y;this.words[E]=m|M,M=I>>>26-y}M&&(this.words[E]=M,this.length++)}if(b!==0){for(E=this.length-1;E>=0;E--)this.words[E+b]=this.words[E];for(E=0;E<b;E++)this.words[E]=0;this.length+=b}return this._strip()},a.prototype.ishln=function(l){return n(this.negative===0),this.iushln(l)},a.prototype.iushrn=function(l,y,b){n(typeof l=="number"&&l>=0);var w;y?w=(y-y%26)/26:w=0;var E=l%26,M=Math.min((l-E)/26,this.length),I=67108863^67108863>>>E<<E,m=b;if(w-=M,w=Math.max(0,w),m){for(var f=0;f<M;f++)m.words[f]=this.words[f];m.length=M}if(M!==0)if(this.length>M)for(this.length-=M,f=0;f<this.length;f++)this.words[f]=this.words[f+M];else this.words[0]=0,this.length=1;var x=0;for(f=this.length-1;f>=0&&(x!==0||f>=w);f--){var B=this.words[f]|0;this.words[f]=x<<26-E|B>>>E,x=B&I}return m&&x!==0&&(m.words[m.length++]=x),this.length===0&&(this.words[0]=0,this.length=1),this._strip()},a.prototype.ishrn=function(l,y,b){return n(this.negative===0),this.iushrn(l,y,b)},a.prototype.shln=function(l){return this.clone().ishln(l)},a.prototype.ushln=function(l){return this.clone().iushln(l)},a.prototype.shrn=function(l){return this.clone().ishrn(l)},a.prototype.ushrn=function(l){return this.clone().iushrn(l)},a.prototype.testn=function(l){n(typeof l=="number"&&l>=0);var y=l%26,b=(l-y)/26,w=1<<y;if(this.length<=b)return!1;var E=this.words[b];return!!(E&w)},a.prototype.imaskn=function(l){n(typeof l=="number"&&l>=0);var y=l%26,b=(l-y)/26;if(n(this.negative===0,"imaskn works only with positive numbers"),this.length<=b)return this;if(y!==0&&b++,this.length=Math.min(b,this.length),y!==0){var w=67108863^67108863>>>y<<y;this.words[this.length-1]&=w}return this._strip()},a.prototype.maskn=function(l){return this.clone().imaskn(l)},a.prototype.iaddn=function(l){return n(typeof l=="number"),n(l<67108864),l<0?this.isubn(-l):this.negative!==0?this.length===1&&(this.words[0]|0)<=l?(this.words[0]=l-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(l),this.negative=1,this):this._iaddn(l)},a.prototype._iaddn=function(l){this.words[0]+=l;for(var y=0;y<this.length&&this.words[y]>=67108864;y++)this.words[y]-=67108864,y===this.length-1?this.words[y+1]=1:this.words[y+1]++;return this.length=Math.max(this.length,y+1),this},a.prototype.isubn=function(l){if(n(typeof l=="number"),n(l<67108864),l<0)return this.iaddn(-l);if(this.negative!==0)return this.negative=0,this.iaddn(l),this.negative=1,this;if(this.words[0]-=l,this.length===1&&this.words[0]<0)this.words[0]=-this.words[0],this.negative=1;else for(var y=0;y<this.length&&this.words[y]<0;y++)this.words[y]+=67108864,this.words[y+1]-=1;return this._strip()},a.prototype.addn=function(l){return this.clone().iaddn(l)},a.prototype.subn=function(l){return this.clone().isubn(l)},a.prototype.iabs=function(){return this.negative=0,this},a.prototype.abs=function(){return this.clone().iabs()},a.prototype._ishlnsubmul=function(l,y,b){var w=l.length+b,E;this._expand(w);var M,I=0;for(E=0;E<l.length;E++){M=(this.words[E+b]|0)+I;var m=(l.words[E]|0)*y;M-=m&67108863,I=(M>>26)-(m/67108864|0),this.words[E+b]=M&67108863}for(;E<this.length-b;E++)M=(this.words[E+b]|0)+I,I=M>>26,this.words[E+b]=M&67108863;if(I===0)return this._strip();for(n(I===-1),I=0,E=0;E<this.length;E++)M=-(this.words[E]|0)+I,I=M>>26,this.words[E]=M&67108863;return this.negative=1,this._strip()},a.prototype._wordDiv=function(l,y){var b=this.length-l.length,w=this.clone(),E=l,M=E.words[E.length-1]|0,I=this._countBits(M);b=26-I,b!==0&&(E=E.ushln(b),w.iushln(b),M=E.words[E.length-1]|0);var m=w.length-E.length,f;if(y!=="mod"){f=new a(null),f.length=m+1,f.words=new Array(f.length);for(var x=0;x<f.length;x++)f.words[x]=0}var B=w.clone()._ishlnsubmul(E,1,m);B.negative===0&&(w=B,f&&(f.words[m]=1));for(var p=m-1;p>=0;p--){var P=(w.words[E.length+p]|0)*67108864+(w.words[E.length+p-1]|0);for(P=Math.min(P/M|0,67108863),w._ishlnsubmul(E,P,p);w.negative!==0;)P--,w.negative=0,w._ishlnsubmul(E,1,p),w.isZero()||(w.negative^=1);f&&(f.words[p]=P)}return f&&f._strip(),w._strip(),y!=="div"&&b!==0&&w.iushrn(b),{div:f||null,mod:w}},a.prototype.divmod=function(l,y,b){if(n(!l.isZero()),this.isZero())return{div:new a(0),mod:new a(0)};var w,E,M;return this.negative!==0&&l.negative===0?(M=this.neg().divmod(l,y),y!=="mod"&&(w=M.div.neg()),y!=="div"&&(E=M.mod.neg(),b&&E.negative!==0&&E.iadd(l)),{div:w,mod:E}):this.negative===0&&l.negative!==0?(M=this.divmod(l.neg(),y),y!=="mod"&&(w=M.div.neg()),{div:w,mod:M.mod}):(this.negative&l.negative)!==0?(M=this.neg().divmod(l.neg(),y),y!=="div"&&(E=M.mod.neg(),b&&E.negative!==0&&E.isub(l)),{div:M.div,mod:E}):l.length>this.length||this.cmp(l)<0?{div:new a(0),mod:this}:l.length===1?y==="div"?{div:this.divn(l.words[0]),mod:null}:y==="mod"?{div:null,mod:new a(this.modrn(l.words[0]))}:{div:this.divn(l.words[0]),mod:new a(this.modrn(l.words[0]))}:this._wordDiv(l,y)},a.prototype.div=function(l){return this.divmod(l,"div",!1).div},a.prototype.mod=function(l){return this.divmod(l,"mod",!1).mod},a.prototype.umod=function(l){return this.divmod(l,"mod",!0).mod},a.prototype.divRound=function(l){var y=this.divmod(l);if(y.mod.isZero())return y.div;var b=y.div.negative!==0?y.mod.isub(l):y.mod,w=l.ushrn(1),E=l.andln(1),M=b.cmp(w);return M<0||E===1&&M===0?y.div:y.div.negative!==0?y.div.isubn(1):y.div.iaddn(1)},a.prototype.modrn=function(l){var y=l<0;y&&(l=-l),n(l<=67108863);for(var b=(1<<26)%l,w=0,E=this.length-1;E>=0;E--)w=(b*w+(this.words[E]|0))%l;return y?-w:w},a.prototype.modn=function(l){return this.modrn(l)},a.prototype.idivn=function(l){var y=l<0;y&&(l=-l),n(l<=67108863);for(var b=0,w=this.length-1;w>=0;w--){var E=(this.words[w]|0)+b*67108864;this.words[w]=E/l|0,b=E%l}return this._strip(),y?this.ineg():this},a.prototype.divn=function(l){return this.clone().idivn(l)},a.prototype.egcd=function(l){n(l.negative===0),n(!l.isZero());var y=this,b=l.clone();y.negative!==0?y=y.umod(l):y=y.clone();for(var w=new a(1),E=new a(0),M=new a(0),I=new a(1),m=0;y.isEven()&&b.isEven();)y.iushrn(1),b.iushrn(1),++m;for(var f=b.clone(),x=y.clone();!y.isZero();){for(var B=0,p=1;(y.words[0]&p)===0&&B<26;++B,p<<=1);if(B>0)for(y.iushrn(B);B-- >0;)(w.isOdd()||E.isOdd())&&(w.iadd(f),E.isub(x)),w.iushrn(1),E.iushrn(1);for(var P=0,O=1;(b.words[0]&O)===0&&P<26;++P,O<<=1);if(P>0)for(b.iushrn(P);P-- >0;)(M.isOdd()||I.isOdd())&&(M.iadd(f),I.isub(x)),M.iushrn(1),I.iushrn(1);y.cmp(b)>=0?(y.isub(b),w.isub(M),E.isub(I)):(b.isub(y),M.isub(w),I.isub(E))}return{a:M,b:I,gcd:b.iushln(m)}},a.prototype._invmp=function(l){n(l.negative===0),n(!l.isZero());var y=this,b=l.clone();y.negative!==0?y=y.umod(l):y=y.clone();for(var w=new a(1),E=new a(0),M=b.clone();y.cmpn(1)>0&&b.cmpn(1)>0;){for(var I=0,m=1;(y.words[0]&m)===0&&I<26;++I,m<<=1);if(I>0)for(y.iushrn(I);I-- >0;)w.isOdd()&&w.iadd(M),w.iushrn(1);for(var f=0,x=1;(b.words[0]&x)===0&&f<26;++f,x<<=1);if(f>0)for(b.iushrn(f);f-- >0;)E.isOdd()&&E.iadd(M),E.iushrn(1);y.cmp(b)>=0?(y.isub(b),w.isub(E)):(b.isub(y),E.isub(w))}var B;return y.cmpn(1)===0?B=w:B=E,B.cmpn(0)<0&&B.iadd(l),B},a.prototype.gcd=function(l){if(this.isZero())return l.abs();if(l.isZero())return this.abs();var y=this.clone(),b=l.clone();y.negative=0,b.negative=0;for(var w=0;y.isEven()&&b.isEven();w++)y.iushrn(1),b.iushrn(1);do{for(;y.isEven();)y.iushrn(1);for(;b.isEven();)b.iushrn(1);var E=y.cmp(b);if(E<0){var M=y;y=b,b=M}else if(E===0||b.cmpn(1)===0)break;y.isub(b)}while(!0);return b.iushln(w)},a.prototype.invm=function(l){return this.egcd(l).a.umod(l)},a.prototype.isEven=function(){return(this.words[0]&1)===0},a.prototype.isOdd=function(){return(this.words[0]&1)===1},a.prototype.andln=function(l){return this.words[0]&l},a.prototype.bincn=function(l){n(typeof l=="number");var y=l%26,b=(l-y)/26,w=1<<y;if(this.length<=b)return this._expand(b+1),this.words[b]|=w,this;for(var E=w,M=b;E!==0&&M<this.length;M++){var I=this.words[M]|0;I+=E,E=I>>>26,I&=67108863,this.words[M]=I}return E!==0&&(this.words[M]=E,this.length++),this},a.prototype.isZero=function(){return this.length===1&&this.words[0]===0},a.prototype.cmpn=function(l){var y=l<0;if(this.negative!==0&&!y)return-1;if(this.negative===0&&y)return 1;this._strip();var b;if(this.length>1)b=1;else{y&&(l=-l),n(l<=67108863,"Number is too big");var w=this.words[0]|0;b=w===l?0:w<l?-1:1}return this.negative!==0?-b|0:b},a.prototype.cmp=function(l){if(this.negative!==0&&l.negative===0)return-1;if(this.negative===0&&l.negative!==0)return 1;var y=this.ucmp(l);return this.negative!==0?-y|0:y},a.prototype.ucmp=function(l){if(this.length>l.length)return 1;if(this.length<l.length)return-1;for(var y=0,b=this.length-1;b>=0;b--){var w=this.words[b]|0,E=l.words[b]|0;if(w!==E){w<E?y=-1:w>E&&(y=1);break}}return y},a.prototype.gtn=function(l){return this.cmpn(l)===1},a.prototype.gt=function(l){return this.cmp(l)===1},a.prototype.gten=function(l){return this.cmpn(l)>=0},a.prototype.gte=function(l){return this.cmp(l)>=0},a.prototype.ltn=function(l){return this.cmpn(l)===-1},a.prototype.lt=function(l){return this.cmp(l)===-1},a.prototype.lten=function(l){return this.cmpn(l)<=0},a.prototype.lte=function(l){return this.cmp(l)<=0},a.prototype.eqn=function(l){return this.cmpn(l)===0},a.prototype.eq=function(l){return this.cmp(l)===0},a.red=function(l){return new $(l)},a.prototype.toRed=function(l){return n(!this.red,"Already a number in reduction context"),n(this.negative===0,"red works only with positives"),l.convertTo(this)._forceRed(l)},a.prototype.fromRed=function(){return n(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},a.prototype._forceRed=function(l){return this.red=l,this},a.prototype.forceRed=function(l){return n(!this.red,"Already a number in reduction context"),this._forceRed(l)},a.prototype.redAdd=function(l){return n(this.red,"redAdd works only with red numbers"),this.red.add(this,l)},a.prototype.redIAdd=function(l){return n(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,l)},a.prototype.redSub=function(l){return n(this.red,"redSub works only with red numbers"),this.red.sub(this,l)},a.prototype.redISub=function(l){return n(this.red,"redISub works only with red numbers"),this.red.isub(this,l)},a.prototype.redShl=function(l){return n(this.red,"redShl works only with red numbers"),this.red.shl(this,l)},a.prototype.redMul=function(l){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,l),this.red.mul(this,l)},a.prototype.redIMul=function(l){return n(this.red,"redMul works only with red numbers"),this.red._verify2(this,l),this.red.imul(this,l)},a.prototype.redSqr=function(){return n(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},a.prototype.redISqr=function(){return n(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},a.prototype.redSqrt=function(){return n(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},a.prototype.redInvm=function(){return n(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},a.prototype.redNeg=function(){return n(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},a.prototype.redPow=function(l){return n(this.red&&!l.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,l)};var F={k256:null,p224:null,p192:null,p25519:null};function z(A,l){this.name=A,this.p=new a(l,16),this.n=this.p.bitLength(),this.k=new a(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}z.prototype._tmp=function(){var l=new a(null);return l.words=new Array(Math.ceil(this.n/13)),l},z.prototype.ireduce=function(l){var y=l,b;do this.split(y,this.tmp),y=this.imulK(y),y=y.iadd(this.tmp),b=y.bitLength();while(b>this.n);var w=b<this.n?-1:y.ucmp(this.p);return w===0?(y.words[0]=0,y.length=1):w>0?y.isub(this.p):y.strip!==void 0?y.strip():y._strip(),y},z.prototype.split=function(l,y){l.iushrn(this.n,0,y)},z.prototype.imulK=function(l){return l.imul(this.k)};function te(){z.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}i(te,z),te.prototype.split=function(l,y){for(var b=4194303,w=Math.min(l.length,9),E=0;E<w;E++)y.words[E]=l.words[E];if(y.length=w,l.length<=9){l.words[0]=0,l.length=1;return}var M=l.words[9];for(y.words[y.length++]=M&b,E=10;E<l.length;E++){var I=l.words[E]|0;l.words[E-10]=(I&b)<<4|M>>>22,M=I}M>>>=22,l.words[E-10]=M,M===0&&l.length>10?l.length-=10:l.length-=9},te.prototype.imulK=function(l){l.words[l.length]=0,l.words[l.length+1]=0,l.length+=2;for(var y=0,b=0;b<l.length;b++){var w=l.words[b]|0;y+=w*977,l.words[b]=y&67108863,y=w*64+(y/67108864|0)}return l.words[l.length-1]===0&&(l.length--,l.words[l.length-1]===0&&l.length--),l};function V(){z.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}i(V,z);function ne(){z.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}i(ne,z);function ue(){z.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}i(ue,z),ue.prototype.imulK=function(l){for(var y=0,b=0;b<l.length;b++){var w=(l.words[b]|0)*19+y,E=w&67108863;w>>>=26,l.words[b]=E,y=w}return y!==0&&(l.words[l.length++]=y),l},a._prime=function(l){if(F[l])return F[l];var y;if(l==="k256")y=new te;else if(l==="p224")y=new V;else if(l==="p192")y=new ne;else if(l==="p25519")y=new ue;else throw new Error("Unknown prime "+l);return F[l]=y,y};function $(A){if(typeof A=="string"){var l=a._prime(A);this.m=l.p,this.prime=l}else n(A.gtn(1),"modulus must be greater than 1"),this.m=A,this.prime=null}$.prototype._verify1=function(l){n(l.negative===0,"red works only with positives"),n(l.red,"red works only with red numbers")},$.prototype._verify2=function(l,y){n((l.negative|y.negative)===0,"red works only with positives"),n(l.red&&l.red===y.red,"red works only with red numbers")},$.prototype.imod=function(l){return this.prime?this.prime.ireduce(l)._forceRed(this):(d(l,l.umod(this.m)._forceRed(this)),l)},$.prototype.neg=function(l){return l.isZero()?l.clone():this.m.sub(l)._forceRed(this)},$.prototype.add=function(l,y){this._verify2(l,y);var b=l.add(y);return b.cmp(this.m)>=0&&b.isub(this.m),b._forceRed(this)},$.prototype.iadd=function(l,y){this._verify2(l,y);var b=l.iadd(y);return b.cmp(this.m)>=0&&b.isub(this.m),b},$.prototype.sub=function(l,y){this._verify2(l,y);var b=l.sub(y);return b.cmpn(0)<0&&b.iadd(this.m),b._forceRed(this)},$.prototype.isub=function(l,y){this._verify2(l,y);var b=l.isub(y);return b.cmpn(0)<0&&b.iadd(this.m),b},$.prototype.shl=function(l,y){return this._verify1(l),this.imod(l.ushln(y))},$.prototype.imul=function(l,y){return this._verify2(l,y),this.imod(l.imul(y))},$.prototype.mul=function(l,y){return this._verify2(l,y),this.imod(l.mul(y))},$.prototype.isqr=function(l){return this.imul(l,l.clone())},$.prototype.sqr=function(l){return this.mul(l,l)},$.prototype.sqrt=function(l){if(l.isZero())return l.clone();var y=this.m.andln(3);if(n(y%2===1),y===3){var b=this.m.add(new a(1)).iushrn(2);return this.pow(l,b)}for(var w=this.m.subn(1),E=0;!w.isZero()&&w.andln(1)===0;)E++,w.iushrn(1);n(!w.isZero());var M=new a(1).toRed(this),I=M.redNeg(),m=this.m.subn(1).iushrn(1),f=this.m.bitLength();for(f=new a(2*f*f).toRed(this);this.pow(f,m).cmp(I)!==0;)f.redIAdd(I);for(var x=this.pow(f,w),B=this.pow(l,w.addn(1).iushrn(1)),p=this.pow(l,w),P=E;p.cmp(M)!==0;){for(var O=p,R=0;O.cmp(M)!==0;R++)O=O.redSqr();n(R<P);var U=this.pow(x,new a(1).iushln(P-R-1));B=B.redMul(U),x=U.redSqr(),p=p.redMul(x),P=R}return B},$.prototype.invm=function(l){var y=l._invmp(this.m);return y.negative!==0?(y.negative=0,this.imod(y).redNeg()):this.imod(y)},$.prototype.pow=function(l,y){if(y.isZero())return new a(1).toRed(this);if(y.cmpn(1)===0)return l.clone();var b=4,w=new Array(1<<b);w[0]=new a(1).toRed(this),w[1]=l;for(var E=2;E<w.length;E++)w[E]=this.mul(w[E-1],l);var M=w[0],I=0,m=0,f=y.bitLength()%26;for(f===0&&(f=26),E=y.length-1;E>=0;E--){for(var x=y.words[E],B=f-1;B>=0;B--){var p=x>>B&1;if(M!==w[0]&&(M=this.sqr(M)),p===0&&I===0){m=0;continue}I<<=1,I|=p,m++,!(m!==b&&(E!==0||B!==0))&&(M=this.mul(M,w[I]),m=0,I=0)}f=26}return M},$.prototype.convertTo=function(l){var y=l.umod(this.m);return y===l?y.clone():y},$.prototype.convertFrom=function(l){var y=l.clone();return y.red=null,y},a.mont=function(l){return new ce(l)};function ce(A){$.call(this,A),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new a(1).iushln(this.shift),this.r2=this.imod(this.r.sqr()),this.rinv=this.r._invmp(this.m),this.minv=this.rinv.mul(this.r).isubn(1).div(this.m),this.minv=this.minv.umod(this.r),this.minv=this.r.sub(this.minv)}i(ce,$),ce.prototype.convertTo=function(l){return this.imod(l.ushln(this.shift))},ce.prototype.convertFrom=function(l){var y=this.imod(l.mul(this.rinv));return y.red=null,y},ce.prototype.imul=function(l,y){if(l.isZero()||y.isZero())return l.words[0]=0,l.length=1,l;var b=l.imul(y),w=b.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),E=b.isub(w).iushrn(this.shift),M=E;return E.cmp(this.m)>=0?M=E.isub(this.m):E.cmpn(0)<0&&(M=E.iadd(this.m)),M._forceRed(this)},ce.prototype.mul=function(l,y){if(l.isZero()||y.isZero())return new a(0)._forceRed(this);var b=l.mul(y),w=b.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),E=b.isub(w).iushrn(this.shift),M=E;return E.cmp(this.m)>=0?M=E.isub(this.m):E.cmpn(0)<0&&(M=E.iadd(this.m)),M._forceRed(this)},ce.prototype.invm=function(l){var y=this.imod(l._invmp(this.m).mul(this.r2));return y._forceRed(this)}})(r,Y)})(_u);var ae=_u.exports;const D0="logger/5.7.0";let Cu=!1,Su=!1;const va={debug:1,default:2,info:2,warning:3,error:4,off:5};let Mu=va.default,Bs=null;function U0(){try{const r=[];if(["NFD","NFC","NFKD","NFKC"].forEach(e=>{try{if("test".normalize(e)!=="test")throw new Error("bad normalize")}catch{r.push(e)}}),r.length)throw new Error("missing "+r.join(", "));if(String.fromCharCode(233).normalize("NFD")!==String.fromCharCode(101,769))throw new Error("broken implementation")}catch(r){return r.message}return null}const Pu=U0();var wa;(function(r){r.DEBUG="DEBUG",r.INFO="INFO",r.WARNING="WARNING",r.ERROR="ERROR",r.OFF="OFF"})(wa||(wa={}));var Rt;(function(r){r.UNKNOWN_ERROR="UNKNOWN_ERROR",r.NOT_IMPLEMENTED="NOT_IMPLEMENTED",r.UNSUPPORTED_OPERATION="UNSUPPORTED_OPERATION",r.NETWORK_ERROR="NETWORK_ERROR",r.SERVER_ERROR="SERVER_ERROR",r.TIMEOUT="TIMEOUT",r.BUFFER_OVERRUN="BUFFER_OVERRUN",r.NUMERIC_FAULT="NUMERIC_FAULT",r.MISSING_NEW="MISSING_NEW",r.INVALID_ARGUMENT="INVALID_ARGUMENT",r.MISSING_ARGUMENT="MISSING_ARGUMENT",r.UNEXPECTED_ARGUMENT="UNEXPECTED_ARGUMENT",r.CALL_EXCEPTION="CALL_EXCEPTION",r.INSUFFICIENT_FUNDS="INSUFFICIENT_FUNDS",r.NONCE_EXPIRED="NONCE_EXPIRED",r.REPLACEMENT_UNDERPRICED="REPLACEMENT_UNDERPRICED",r.UNPREDICTABLE_GAS_LIMIT="UNPREDICTABLE_GAS_LIMIT",r.TRANSACTION_REPLACED="TRANSACTION_REPLACED",r.ACTION_REJECTED="ACTION_REJECTED"})(Rt||(Rt={}));const ku="0123456789abcdef";class _{constructor(e){Object.defineProperty(this,"version",{enumerable:!0,value:e,writable:!1})}_log(e,t){const n=e.toLowerCase();va[n]==null&&this.throwArgumentError("invalid log level name","logLevel",e),!(Mu>va[n])&&console.log.apply(console,t)}debug(...e){this._log(_.levels.DEBUG,e)}info(...e){this._log(_.levels.INFO,e)}warn(...e){this._log(_.levels.WARNING,e)}makeError(e,t,n){if(Su)return this.makeError("censored error",t,{});t||(t=_.errors.UNKNOWN_ERROR),n||(n={});const i=[];Object.keys(n).forEach(c=>{const u=n[c];try{if(u instanceof Uint8Array){let d="";for(let h=0;h<u.length;h++)d+=ku[u[h]>>4],d+=ku[u[h]&15];i.push(c+"=Uint8Array(0x"+d+")")}else i.push(c+"="+JSON.stringify(u))}catch{i.push(c+"="+JSON.stringify(n[c].toString()))}}),i.push(`code=${t}`),i.push(`version=${this.version}`);const a=e;let s="";switch(t){case Rt.NUMERIC_FAULT:{s="NUMERIC_FAULT";const c=e;switch(c){case"overflow":case"underflow":case"division-by-zero":s+="-"+c;break;case"negative-power":case"negative-width":s+="-unsupported";break;case"unbound-bitwise-result":s+="-unbound-result";break}break}case Rt.CALL_EXCEPTION:case Rt.INSUFFICIENT_FUNDS:case Rt.MISSING_NEW:case Rt.NONCE_EXPIRED:case Rt.REPLACEMENT_UNDERPRICED:case Rt.TRANSACTION_REPLACED:case Rt.UNPREDICTABLE_GAS_LIMIT:s=t;break}s&&(e+=" [ See: https://links.ethers.org/v5-errors-"+s+" ]"),i.length&&(e+=" ("+i.join(", ")+")");const o=new Error(e);return o.reason=a,o.code=t,Object.keys(n).forEach(function(c){o[c]=n[c]}),o}throwError(e,t,n){throw this.makeError(e,t,n)}throwArgumentError(e,t,n){return this.throwError(e,_.errors.INVALID_ARGUMENT,{argument:t,value:n})}assert(e,t,n,i){e||this.throwError(t,n,i)}assertArgument(e,t,n,i){e||this.throwArgumentError(t,n,i)}checkNormalize(e){Pu&&this.throwError("platform missing String.prototype.normalize",_.errors.UNSUPPORTED_OPERATION,{operation:"String.prototype.normalize",form:Pu})}checkSafeUint53(e,t){typeof e=="number"&&(t==null&&(t="value not safe"),(e<0||e>=9007199254740991)&&this.throwError(t,_.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"out-of-safe-range",value:e}),e%1&&this.throwError(t,_.errors.NUMERIC_FAULT,{operation:"checkSafeInteger",fault:"non-integer",value:e}))}checkArgumentCount(e,t,n){n?n=": "+n:n="",e<t&&this.throwError("missing argument"+n,_.errors.MISSING_ARGUMENT,{count:e,expectedCount:t}),e>t&&this.throwError("too many arguments"+n,_.errors.UNEXPECTED_ARGUMENT,{count:e,expectedCount:t})}checkNew(e,t){(e===Object||e==null)&&this.throwError("missing new",_.errors.MISSING_NEW,{name:t.name})}checkAbstract(e,t){e===t?this.throwError("cannot instantiate abstract class "+JSON.stringify(t.name)+" directly; use a sub-class",_.errors.UNSUPPORTED_OPERATION,{name:e.name,operation:"new"}):(e===Object||e==null)&&this.throwError("missing new",_.errors.MISSING_NEW,{name:t.name})}static globalLogger(){return Bs||(Bs=new _(D0)),Bs}static setCensorship(e,t){if(!e&&t&&this.globalLogger().throwError("cannot permanently disable censorship",_.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"}),Cu){if(!e)return;this.globalLogger().throwError("error censorship permanent",_.errors.UNSUPPORTED_OPERATION,{operation:"setCensorship"})}Su=!!e,Cu=!!t}static setLogLevel(e){const t=va[e.toLowerCase()];if(t==null){_.globalLogger().warn("invalid log level - "+e);return}Mu=t}static from(e){return new _(e)}}_.errors=Rt,_.levels=wa;var L0=Object.freeze(Object.defineProperty({__proto__:null,get LogLevel(){return wa},get ErrorCode(){return Rt},Logger:_},Symbol.toStringTag,{value:"Module"}));const G0="bytes/5.7.0",ct=new _(G0);function Bu(r){return!!r.toHexString}function ri(r){return r.slice||(r.slice=function(){const e=Array.prototype.slice.call(arguments);return ri(new Uint8Array(Array.prototype.slice.apply(r,e)))}),r}function ni(r){return se(r)&&!(r.length%2)||Dr(r)}function Iu(r){return typeof r=="number"&&r==r&&r%1===0}function Dr(r){if(r==null)return!1;if(r.constructor===Uint8Array)return!0;if(typeof r=="string"||!Iu(r.length)||r.length<0)return!1;for(let e=0;e<r.length;e++){const t=r[e];if(!Iu(t)||t<0||t>=256)return!1}return!0}function q(r,e){if(e||(e={}),typeof r=="number"){ct.checkSafeUint53(r,"invalid arrayify value");const t=[];for(;r;)t.unshift(r&255),r=parseInt(String(r/256));return t.length===0&&t.push(0),ri(new Uint8Array(t))}if(e.allowMissingPrefix&&typeof r=="string"&&r.substring(0,2)!=="0x"&&(r="0x"+r),Bu(r)&&(r=r.toHexString()),se(r)){let t=r.substring(2);t.length%2&&(e.hexPad==="left"?t="0"+t:e.hexPad==="right"?t+="0":ct.throwArgumentError("hex data is odd-length","value",r));const n=[];for(let i=0;i<t.length;i+=2)n.push(parseInt(t.substring(i,i+2),16));return ri(new Uint8Array(n))}return Dr(r)?ri(new Uint8Array(r)):ct.throwArgumentError("invalid arrayify value","value",r)}function ve(r){const e=r.map(i=>q(i)),t=e.reduce((i,a)=>i+a.length,0),n=new Uint8Array(t);return e.reduce((i,a)=>(n.set(a,i),i+