@smartledger/bsv 7.7.0 → 7.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/bsv-shamir.min.js CHANGED
@@ -1,4 +1,4 @@
1
- var bsvShamir=(()=>{var Db=Object.create;var ml=Object.defineProperty;var Ub=Object.getOwnPropertyDescriptor;var Nb=Object.getOwnPropertyNames;var Lb=Object.getPrototypeOf,Fb=Object.prototype.hasOwnProperty;var jb=(t,e,r)=>()=>{if(r)throw r[0];try{return t&&(e=t(t=0)),e}catch(n){throw r=[n],n}};var R=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}};var Hb=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Nb(e))!Fb.call(t,i)&&i!==r&&ml(t,i,{get:()=>e[i],enumerable:!(n=Ub(e,i))||n.enumerable});return t};var bl=(t,e,r)=>(r=t!=null?Db(Lb(t)):{},Hb(e||!t||!t.__esModule?ml(r,"default",{value:t,enumerable:!0}):r,t));var El=R((CB,Ml)=>{w();var Ze=Ml.exports={},zt,Gt;function es(){throw new Error("setTimeout has not been defined")}function ts(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?zt=setTimeout:zt=es}catch{zt=es}try{typeof clearTimeout=="function"?Gt=clearTimeout:Gt=ts}catch{Gt=ts}})();function wl(t){if(zt===setTimeout)return setTimeout(t,0);if((zt===es||!zt)&&setTimeout)return zt=setTimeout,setTimeout(t,0);try{return zt(t,0)}catch{try{return zt.call(null,t,0)}catch{return zt.call(this,t,0)}}}function Kb(t){if(Gt===clearTimeout)return clearTimeout(t);if((Gt===ts||!Gt)&&clearTimeout)return Gt=clearTimeout,clearTimeout(t);try{return Gt(t)}catch{try{return Gt.call(null,t)}catch{return Gt.call(this,t)}}}var sr=[],Ni=!1,ai,Za=-1;function Wb(){!Ni||!ai||(Ni=!1,ai.length?sr=ai.concat(sr):Za=-1,sr.length&&_l())}function _l(){if(!Ni){var t=wl(Wb);Ni=!0;for(var e=sr.length;e;){for(ai=sr,sr=[];++Za<e;)ai&&ai[Za].run();Za=-1,e=sr.length}ai=null,Ni=!1,Kb(t)}}Ze.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];sr.push(new xl(t,e)),sr.length===1&&!Ni&&wl(_l)};function xl(t,e){this.fun=t,this.array=e}xl.prototype.run=function(){this.fun.apply(null,this.array)};Ze.title="browser";Ze.browser=!0;Ze.env={};Ze.argv=[];Ze.version="";Ze.versions={};function ur(){}Ze.on=ur;Ze.addListener=ur;Ze.once=ur;Ze.off=ur;Ze.removeListener=ur;Ze.removeAllListeners=ur;Ze.emit=ur;Ze.prependListener=ur;Ze.prependOnceListener=ur;Ze.listeners=function(t){return[]};Ze.binding=function(t){throw new Error("process.binding is not supported")};Ze.cwd=function(){return"/"};Ze.chdir=function(t){throw new Error("process.chdir is not supported")};Ze.umask=function(){return 0}});var Al=R(Ya=>{"use strict";w();Ya.byteLength=Gb;Ya.toByteArray=$b;Ya.fromByteArray=Xb;var Vt=[],wt=[],zb=typeof Uint8Array<"u"?Uint8Array:Array,rs="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(oi=0,Sl=rs.length;oi<Sl;++oi)Vt[oi]=rs[oi],wt[rs.charCodeAt(oi)]=oi;var oi,Sl;wt[45]=62;wt[95]=63;function Bl(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");r===-1&&(r=e);var n=r===e?0:4-r%4;return[r,n]}function Gb(t){var e=Bl(t),r=e[0],n=e[1];return(r+n)*3/4-n}function Vb(t,e,r){return(e+r)*3/4-r}function $b(t){var e,r=Bl(t),n=r[0],i=r[1],a=new zb(Vb(t,n,i)),f=0,v=i>0?n-4:n,m;for(m=0;m<v;m+=4)e=wt[t.charCodeAt(m)]<<18|wt[t.charCodeAt(m+1)]<<12|wt[t.charCodeAt(m+2)]<<6|wt[t.charCodeAt(m+3)],a[f++]=e>>16&255,a[f++]=e>>8&255,a[f++]=e&255;return i===2&&(e=wt[t.charCodeAt(m)]<<2|wt[t.charCodeAt(m+1)]>>4,a[f++]=e&255),i===1&&(e=wt[t.charCodeAt(m)]<<10|wt[t.charCodeAt(m+1)]<<4|wt[t.charCodeAt(m+2)]>>2,a[f++]=e>>8&255,a[f++]=e&255),a}function Zb(t){return Vt[t>>18&63]+Vt[t>>12&63]+Vt[t>>6&63]+Vt[t&63]}function Yb(t,e,r){for(var n,i=[],a=e;a<r;a+=3)n=(t[a]<<16&16711680)+(t[a+1]<<8&65280)+(t[a+2]&255),i.push(Zb(n));return i.join("")}function Xb(t){for(var e,r=t.length,n=r%3,i=[],a=16383,f=0,v=r-n;f<v;f+=a)i.push(Yb(t,f,f+a>v?v:f+a));return n===1?(e=t[r-1],i.push(Vt[e>>2]+Vt[e<<4&63]+"==")):n===2&&(e=(t[r-2]<<8)+t[r-1],i.push(Vt[e>>10]+Vt[e>>4&63]+Vt[e<<2&63]+"=")),i.join("")}});var Rl=R(is=>{w();is.read=function(t,e,r,n,i){var a,f,v=i*8-n-1,m=(1<<v)-1,E=m>>1,A=-7,q=r?i-1:0,I=r?-1:1,C=t[e+q];for(q+=I,a=C&(1<<-A)-1,C>>=-A,A+=v;A>0;a=a*256+t[e+q],q+=I,A-=8);for(f=a&(1<<-A)-1,a>>=-A,A+=n;A>0;f=f*256+t[e+q],q+=I,A-=8);if(a===0)a=1-E;else{if(a===m)return f?NaN:(C?-1:1)*(1/0);f=f+Math.pow(2,n),a=a-E}return(C?-1:1)*f*Math.pow(2,a-n)};is.write=function(t,e,r,n,i,a){var f,v,m,E=a*8-i-1,A=(1<<E)-1,q=A>>1,I=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,C=n?0:a-1,j=n?1:-1,V=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(v=isNaN(e)?1:0,f=A):(f=Math.floor(Math.log(e)/Math.LN2),e*(m=Math.pow(2,-f))<1&&(f--,m*=2),f+q>=1?e+=I/m:e+=I*Math.pow(2,1-q),e*m>=2&&(f++,m/=2),f+q>=A?(v=0,f=A):f+q>=1?(v=(e*m-1)*Math.pow(2,i),f=f+q):(v=e*Math.pow(2,q-1)*Math.pow(2,i),f=0));i>=8;t[r+C]=v&255,C+=j,v/=256,i-=8);for(f=f<<i|v,E+=i;E>0;t[r+C]=f&255,C+=j,f/=256,E-=8);t[r+C-j]|=V*128}});var ft=R(Hi=>{"use strict";w();var ns=Al(),Fi=Rl(),ql=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;Hi.Buffer=T;Hi.SlowBuffer=i2;Hi.INSPECT_MAX_BYTES=50;var Xa=2147483647;Hi.kMaxLength=Xa;T.TYPED_ARRAY_SUPPORT=Jb();!T.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function Jb(){try{let t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),t.foo()===42}catch{return!1}}Object.defineProperty(T.prototype,"parent",{enumerable:!0,get:function(){if(T.isBuffer(this))return this.buffer}});Object.defineProperty(T.prototype,"offset",{enumerable:!0,get:function(){if(T.isBuffer(this))return this.byteOffset}});function hr(t){if(t>Xa)throw new RangeError('The value "'+t+'" is invalid for option "size"');let e=new Uint8Array(t);return Object.setPrototypeOf(e,T.prototype),e}function T(t,e,r){if(typeof t=="number"){if(typeof e=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return ss(t)}return Cl(t,e,r)}T.poolSize=8192;function Cl(t,e,r){if(typeof t=="string")return e2(t,e);if(ArrayBuffer.isView(t))return t2(t);if(t==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if($t(t,ArrayBuffer)||t&&$t(t.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&($t(t,SharedArrayBuffer)||t&&$t(t.buffer,SharedArrayBuffer)))return os(t,e,r);if(typeof t=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');let n=t.valueOf&&t.valueOf();if(n!=null&&n!==t)return T.from(n,e,r);let i=r2(t);if(i)return i;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof t[Symbol.toPrimitive]=="function")return T.from(t[Symbol.toPrimitive]("string"),e,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}T.from=function(t,e,r){return Cl(t,e,r)};Object.setPrototypeOf(T.prototype,Uint8Array.prototype);Object.setPrototypeOf(T,Uint8Array);function Ol(t){if(typeof t!="number")throw new TypeError('"size" argument must be of type number');if(t<0)throw new RangeError('The value "'+t+'" is invalid for option "size"')}function Qb(t,e,r){return Ol(t),t<=0?hr(t):e!==void 0?typeof r=="string"?hr(t).fill(e,r):hr(t).fill(e):hr(t)}T.alloc=function(t,e,r){return Qb(t,e,r)};function ss(t){return Ol(t),hr(t<0?0:us(t)|0)}T.allocUnsafe=function(t){return ss(t)};T.allocUnsafeSlow=function(t){return ss(t)};function e2(t,e){if((typeof e!="string"||e==="")&&(e="utf8"),!T.isEncoding(e))throw new TypeError("Unknown encoding: "+e);let r=Pl(t,e)|0,n=hr(r),i=n.write(t,e);return i!==r&&(n=n.slice(0,i)),n}function as(t){let e=t.length<0?0:us(t.length)|0,r=hr(e);for(let n=0;n<e;n+=1)r[n]=t[n]&255;return r}function t2(t){if($t(t,Uint8Array)){let e=new Uint8Array(t);return os(e.buffer,e.byteOffset,e.byteLength)}return as(t)}function os(t,e,r){if(e<0||t.byteLength<e)throw new RangeError('"offset" is outside of buffer bounds');if(t.byteLength<e+(r||0))throw new RangeError('"length" is outside of buffer bounds');let n;return e===void 0&&r===void 0?n=new Uint8Array(t):r===void 0?n=new Uint8Array(t,e):n=new Uint8Array(t,e,r),Object.setPrototypeOf(n,T.prototype),n}function r2(t){if(T.isBuffer(t)){let e=us(t.length)|0,r=hr(e);return r.length===0||t.copy(r,0,0,e),r}if(t.length!==void 0)return typeof t.length!="number"||ls(t.length)?hr(0):as(t);if(t.type==="Buffer"&&Array.isArray(t.data))return as(t.data)}function us(t){if(t>=Xa)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Xa.toString(16)+" bytes");return t|0}function i2(t){return+t!=t&&(t=0),T.alloc(+t)}T.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==T.prototype};T.compare=function(e,r){if($t(e,Uint8Array)&&(e=T.from(e,e.offset,e.byteLength)),$t(r,Uint8Array)&&(r=T.from(r,r.offset,r.byteLength)),!T.isBuffer(e)||!T.isBuffer(r))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===r)return 0;let n=e.length,i=r.length;for(let a=0,f=Math.min(n,i);a<f;++a)if(e[a]!==r[a]){n=e[a],i=r[a];break}return n<i?-1:i<n?1:0};T.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};T.concat=function(e,r){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(e.length===0)return T.alloc(0);let n;if(r===void 0)for(r=0,n=0;n<e.length;++n)r+=e[n].length;let i=T.allocUnsafe(r),a=0;for(n=0;n<e.length;++n){let f=e[n];if($t(f,Uint8Array))a+f.length>i.length?(T.isBuffer(f)||(f=T.from(f)),f.copy(i,a)):Uint8Array.prototype.set.call(i,f,a);else if(T.isBuffer(f))f.copy(i,a);else throw new TypeError('"list" argument must be an Array of Buffers');a+=f.length}return i};function Pl(t,e){if(T.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||$t(t,ArrayBuffer))return t.byteLength;if(typeof t!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);let r=t.length,n=arguments.length>2&&arguments[2]===!0;if(!n&&r===0)return 0;let i=!1;for(;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return fs(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return r*2;case"hex":return r>>>1;case"base64":return Wl(t).length;default:if(i)return n?-1:fs(t).length;e=(""+e).toLowerCase(),i=!0}}T.byteLength=Pl;function n2(t,e,r){let n=!1;if((e===void 0||e<0)&&(e=0),e>this.length||((r===void 0||r>this.length)&&(r=this.length),r<=0)||(r>>>=0,e>>>=0,r<=e))return"";for(t||(t="utf8");;)switch(t){case"hex":return p2(this,e,r);case"utf8":case"utf-8":return Ul(this,e,r);case"ascii":return c2(this,e,r);case"latin1":case"binary":return d2(this,e,r);case"base64":return h2(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return v2(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}T.prototype._isBuffer=!0;function fi(t,e,r){let n=t[e];t[e]=t[r],t[r]=n}T.prototype.swap16=function(){let e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let r=0;r<e;r+=2)fi(this,r,r+1);return this};T.prototype.swap32=function(){let e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let r=0;r<e;r+=4)fi(this,r,r+3),fi(this,r+1,r+2);return this};T.prototype.swap64=function(){let e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let r=0;r<e;r+=8)fi(this,r,r+7),fi(this,r+1,r+6),fi(this,r+2,r+5),fi(this,r+3,r+4);return this};T.prototype.toString=function(){let e=this.length;return e===0?"":arguments.length===0?Ul(this,0,e):n2.apply(this,arguments)};T.prototype.toLocaleString=T.prototype.toString;T.prototype.equals=function(e){if(!T.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e?!0:T.compare(this,e)===0};T.prototype.inspect=function(){let e="",r=Hi.INSPECT_MAX_BYTES;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"};ql&&(T.prototype[ql]=T.prototype.inspect);T.prototype.compare=function(e,r,n,i,a){if($t(e,Uint8Array)&&(e=T.from(e,e.offset,e.byteLength)),!T.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(r===void 0&&(r=0),n===void 0&&(n=e?e.length:0),i===void 0&&(i=0),a===void 0&&(a=this.length),r<0||n>e.length||i<0||a>this.length)throw new RangeError("out of range index");if(i>=a&&r>=n)return 0;if(i>=a)return-1;if(r>=n)return 1;if(r>>>=0,n>>>=0,i>>>=0,a>>>=0,this===e)return 0;let f=a-i,v=n-r,m=Math.min(f,v),E=this.slice(i,a),A=e.slice(r,n);for(let q=0;q<m;++q)if(E[q]!==A[q]){f=E[q],v=A[q];break}return f<v?-1:v<f?1:0};function Dl(t,e,r,n,i){if(t.length===0)return-1;if(typeof r=="string"?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,ls(r)&&(r=i?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(i)return-1;r=t.length-1}else if(r<0)if(i)r=0;else return-1;if(typeof e=="string"&&(e=T.from(e,n)),T.isBuffer(e))return e.length===0?-1:Il(t,e,r,n,i);if(typeof e=="number")return e=e&255,typeof Uint8Array.prototype.indexOf=="function"?i?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):Il(t,[e],r,n,i);throw new TypeError("val must be string, number or Buffer")}function Il(t,e,r,n,i){let a=1,f=t.length,v=e.length;if(n!==void 0&&(n=String(n).toLowerCase(),n==="ucs2"||n==="ucs-2"||n==="utf16le"||n==="utf-16le")){if(t.length<2||e.length<2)return-1;a=2,f/=2,v/=2,r/=2}function m(A,q){return a===1?A[q]:A.readUInt16BE(q*a)}let E;if(i){let A=-1;for(E=r;E<f;E++)if(m(t,E)===m(e,A===-1?0:E-A)){if(A===-1&&(A=E),E-A+1===v)return A*a}else A!==-1&&(E-=E-A),A=-1}else for(r+v>f&&(r=f-v),E=r;E>=0;E--){let A=!0;for(let q=0;q<v;q++)if(m(t,E+q)!==m(e,q)){A=!1;break}if(A)return E}return-1}T.prototype.includes=function(e,r,n){return this.indexOf(e,r,n)!==-1};T.prototype.indexOf=function(e,r,n){return Dl(this,e,r,n,!0)};T.prototype.lastIndexOf=function(e,r,n){return Dl(this,e,r,n,!1)};function a2(t,e,r,n){r=Number(r)||0;let i=t.length-r;n?(n=Number(n),n>i&&(n=i)):n=i;let a=e.length;n>a/2&&(n=a/2);let f;for(f=0;f<n;++f){let v=parseInt(e.substr(f*2,2),16);if(ls(v))return f;t[r+f]=v}return f}function o2(t,e,r,n){return Ja(fs(e,t.length-r),t,r,n)}function f2(t,e,r,n){return Ja(b2(e),t,r,n)}function s2(t,e,r,n){return Ja(Wl(e),t,r,n)}function u2(t,e,r,n){return Ja(w2(e,t.length-r),t,r,n)}T.prototype.write=function(e,r,n,i){if(r===void 0)i="utf8",n=this.length,r=0;else if(n===void 0&&typeof r=="string")i=r,n=this.length,r=0;else if(isFinite(r))r=r>>>0,isFinite(n)?(n=n>>>0,i===void 0&&(i="utf8")):(i=n,n=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let a=this.length-r;if((n===void 0||n>a)&&(n=a),e.length>0&&(n<0||r<0)||r>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");let f=!1;for(;;)switch(i){case"hex":return a2(this,e,r,n);case"utf8":case"utf-8":return o2(this,e,r,n);case"ascii":case"latin1":case"binary":return f2(this,e,r,n);case"base64":return s2(this,e,r,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return u2(this,e,r,n);default:if(f)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),f=!0}};T.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function h2(t,e,r){return e===0&&r===t.length?ns.fromByteArray(t):ns.fromByteArray(t.slice(e,r))}function Ul(t,e,r){r=Math.min(t.length,r);let n=[],i=e;for(;i<r;){let a=t[i],f=null,v=a>239?4:a>223?3:a>191?2:1;if(i+v<=r){let m,E,A,q;switch(v){case 1:a<128&&(f=a);break;case 2:m=t[i+1],(m&192)===128&&(q=(a&31)<<6|m&63,q>127&&(f=q));break;case 3:m=t[i+1],E=t[i+2],(m&192)===128&&(E&192)===128&&(q=(a&15)<<12|(m&63)<<6|E&63,q>2047&&(q<55296||q>57343)&&(f=q));break;case 4:m=t[i+1],E=t[i+2],A=t[i+3],(m&192)===128&&(E&192)===128&&(A&192)===128&&(q=(a&15)<<18|(m&63)<<12|(E&63)<<6|A&63,q>65535&&q<1114112&&(f=q))}}f===null?(f=65533,v=1):f>65535&&(f-=65536,n.push(f>>>10&1023|55296),f=56320|f&1023),n.push(f),i+=v}return l2(n)}var kl=4096;function l2(t){let e=t.length;if(e<=kl)return String.fromCharCode.apply(String,t);let r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=kl));return r}function c2(t,e,r){let n="";r=Math.min(t.length,r);for(let i=e;i<r;++i)n+=String.fromCharCode(t[i]&127);return n}function d2(t,e,r){let n="";r=Math.min(t.length,r);for(let i=e;i<r;++i)n+=String.fromCharCode(t[i]);return n}function p2(t,e,r){let n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);let i="";for(let a=e;a<r;++a)i+=_2[t[a]];return i}function v2(t,e,r){let n=t.slice(e,r),i="";for(let a=0;a<n.length-1;a+=2)i+=String.fromCharCode(n[a]+n[a+1]*256);return i}T.prototype.slice=function(e,r){let n=this.length;e=~~e,r=r===void 0?n:~~r,e<0?(e+=n,e<0&&(e=0)):e>n&&(e=n),r<0?(r+=n,r<0&&(r=0)):r>n&&(r=n),r<e&&(r=e);let i=this.subarray(e,r);return Object.setPrototypeOf(i,T.prototype),i};function rt(t,e,r){if(t%1!==0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}T.prototype.readUintLE=T.prototype.readUIntLE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=this[e],a=1,f=0;for(;++f<r&&(a*=256);)i+=this[e+f]*a;return i};T.prototype.readUintBE=T.prototype.readUIntBE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=this[e+--r],a=1;for(;r>0&&(a*=256);)i+=this[e+--r]*a;return i};T.prototype.readUint8=T.prototype.readUInt8=function(e,r){return e=e>>>0,r||rt(e,1,this.length),this[e]};T.prototype.readUint16LE=T.prototype.readUInt16LE=function(e,r){return e=e>>>0,r||rt(e,2,this.length),this[e]|this[e+1]<<8};T.prototype.readUint16BE=T.prototype.readUInt16BE=function(e,r){return e=e>>>0,r||rt(e,2,this.length),this[e]<<8|this[e+1]};T.prototype.readUint32LE=T.prototype.readUInt32LE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216};T.prototype.readUint32BE=T.prototype.readUInt32BE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])};T.prototype.readBigUInt64LE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=r+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24,a=this[++e]+this[++e]*2**8+this[++e]*2**16+n*2**24;return BigInt(i)+(BigInt(a)<<BigInt(32))});T.prototype.readBigUInt64BE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=r*2**24+this[++e]*2**16+this[++e]*2**8+this[++e],a=this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n;return(BigInt(i)<<BigInt(32))+BigInt(a)});T.prototype.readIntLE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=this[e],a=1,f=0;for(;++f<r&&(a*=256);)i+=this[e+f]*a;return a*=128,i>=a&&(i-=Math.pow(2,8*r)),i};T.prototype.readIntBE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=r,a=1,f=this[e+--i];for(;i>0&&(a*=256);)f+=this[e+--i]*a;return a*=128,f>=a&&(f-=Math.pow(2,8*r)),f};T.prototype.readInt8=function(e,r){return e=e>>>0,r||rt(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]};T.prototype.readInt16LE=function(e,r){e=e>>>0,r||rt(e,2,this.length);let n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n};T.prototype.readInt16BE=function(e,r){e=e>>>0,r||rt(e,2,this.length);let n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n};T.prototype.readInt32LE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24};T.prototype.readInt32BE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]};T.prototype.readBigInt64LE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=this[e+4]+this[e+5]*2**8+this[e+6]*2**16+(n<<24);return(BigInt(i)<<BigInt(32))+BigInt(r+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24)});T.prototype.readBigInt64BE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=(r<<24)+this[++e]*2**16+this[++e]*2**8+this[++e];return(BigInt(i)<<BigInt(32))+BigInt(this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n)});T.prototype.readFloatLE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),Fi.read(this,e,!0,23,4)};T.prototype.readFloatBE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),Fi.read(this,e,!1,23,4)};T.prototype.readDoubleLE=function(e,r){return e=e>>>0,r||rt(e,8,this.length),Fi.read(this,e,!0,52,8)};T.prototype.readDoubleBE=function(e,r){return e=e>>>0,r||rt(e,8,this.length),Fi.read(this,e,!1,52,8)};function vt(t,e,r,n,i,a){if(!T.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||e<a)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}T.prototype.writeUintLE=T.prototype.writeUIntLE=function(e,r,n,i){if(e=+e,r=r>>>0,n=n>>>0,!i){let v=Math.pow(2,8*n)-1;vt(this,e,r,n,v,0)}let a=1,f=0;for(this[r]=e&255;++f<n&&(a*=256);)this[r+f]=e/a&255;return r+n};T.prototype.writeUintBE=T.prototype.writeUIntBE=function(e,r,n,i){if(e=+e,r=r>>>0,n=n>>>0,!i){let v=Math.pow(2,8*n)-1;vt(this,e,r,n,v,0)}let a=n-1,f=1;for(this[r+a]=e&255;--a>=0&&(f*=256);)this[r+a]=e/f&255;return r+n};T.prototype.writeUint8=T.prototype.writeUInt8=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,1,255,0),this[r]=e&255,r+1};T.prototype.writeUint16LE=T.prototype.writeUInt16LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,65535,0),this[r]=e&255,this[r+1]=e>>>8,r+2};T.prototype.writeUint16BE=T.prototype.writeUInt16BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,65535,0),this[r]=e>>>8,this[r+1]=e&255,r+2};T.prototype.writeUint32LE=T.prototype.writeUInt32LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,4294967295,0),this[r+3]=e>>>24,this[r+2]=e>>>16,this[r+1]=e>>>8,this[r]=e&255,r+4};T.prototype.writeUint32BE=T.prototype.writeUInt32BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,4294967295,0),this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255,r+4};function Nl(t,e,r,n,i){Kl(e,n,i,t,r,7);let a=Number(e&BigInt(4294967295));t[r++]=a,a=a>>8,t[r++]=a,a=a>>8,t[r++]=a,a=a>>8,t[r++]=a;let f=Number(e>>BigInt(32)&BigInt(4294967295));return t[r++]=f,f=f>>8,t[r++]=f,f=f>>8,t[r++]=f,f=f>>8,t[r++]=f,r}function Ll(t,e,r,n,i){Kl(e,n,i,t,r,7);let a=Number(e&BigInt(4294967295));t[r+7]=a,a=a>>8,t[r+6]=a,a=a>>8,t[r+5]=a,a=a>>8,t[r+4]=a;let f=Number(e>>BigInt(32)&BigInt(4294967295));return t[r+3]=f,f=f>>8,t[r+2]=f,f=f>>8,t[r+1]=f,f=f>>8,t[r]=f,r+8}T.prototype.writeBigUInt64LE=Ir(function(e,r=0){return Nl(this,e,r,BigInt(0),BigInt("0xffffffffffffffff"))});T.prototype.writeBigUInt64BE=Ir(function(e,r=0){return Ll(this,e,r,BigInt(0),BigInt("0xffffffffffffffff"))});T.prototype.writeIntLE=function(e,r,n,i){if(e=+e,r=r>>>0,!i){let m=Math.pow(2,8*n-1);vt(this,e,r,n,m-1,-m)}let a=0,f=1,v=0;for(this[r]=e&255;++a<n&&(f*=256);)e<0&&v===0&&this[r+a-1]!==0&&(v=1),this[r+a]=(e/f>>0)-v&255;return r+n};T.prototype.writeIntBE=function(e,r,n,i){if(e=+e,r=r>>>0,!i){let m=Math.pow(2,8*n-1);vt(this,e,r,n,m-1,-m)}let a=n-1,f=1,v=0;for(this[r+a]=e&255;--a>=0&&(f*=256);)e<0&&v===0&&this[r+a+1]!==0&&(v=1),this[r+a]=(e/f>>0)-v&255;return r+n};T.prototype.writeInt8=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,1,127,-128),e<0&&(e=255+e+1),this[r]=e&255,r+1};T.prototype.writeInt16LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,32767,-32768),this[r]=e&255,this[r+1]=e>>>8,r+2};T.prototype.writeInt16BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,32767,-32768),this[r]=e>>>8,this[r+1]=e&255,r+2};T.prototype.writeInt32LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,2147483647,-2147483648),this[r]=e&255,this[r+1]=e>>>8,this[r+2]=e>>>16,this[r+3]=e>>>24,r+4};T.prototype.writeInt32BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255,r+4};T.prototype.writeBigInt64LE=Ir(function(e,r=0){return Nl(this,e,r,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});T.prototype.writeBigInt64BE=Ir(function(e,r=0){return Ll(this,e,r,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Fl(t,e,r,n,i,a){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function jl(t,e,r,n,i){return e=+e,r=r>>>0,i||Fl(t,e,r,4,34028234663852886e22,-34028234663852886e22),Fi.write(t,e,r,n,23,4),r+4}T.prototype.writeFloatLE=function(e,r,n){return jl(this,e,r,!0,n)};T.prototype.writeFloatBE=function(e,r,n){return jl(this,e,r,!1,n)};function Hl(t,e,r,n,i){return e=+e,r=r>>>0,i||Fl(t,e,r,8,17976931348623157e292,-17976931348623157e292),Fi.write(t,e,r,n,52,8),r+8}T.prototype.writeDoubleLE=function(e,r,n){return Hl(this,e,r,!0,n)};T.prototype.writeDoubleBE=function(e,r,n){return Hl(this,e,r,!1,n)};T.prototype.copy=function(e,r,n,i){if(!T.isBuffer(e))throw new TypeError("argument should be a Buffer");if(n||(n=0),!i&&i!==0&&(i=this.length),r>=e.length&&(r=e.length),r||(r=0),i>0&&i<n&&(i=n),i===n||e.length===0||this.length===0)return 0;if(r<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-r<i-n&&(i=e.length-r+n);let a=i-n;return this===e&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(r,n,i):Uint8Array.prototype.set.call(e,this.subarray(n,i),r),a};T.prototype.fill=function(e,r,n,i){if(typeof e=="string"){if(typeof r=="string"?(i=r,r=0,n=this.length):typeof n=="string"&&(i=n,n=this.length),i!==void 0&&typeof i!="string")throw new TypeError("encoding must be a string");if(typeof i=="string"&&!T.isEncoding(i))throw new TypeError("Unknown encoding: "+i);if(e.length===1){let f=e.charCodeAt(0);(i==="utf8"&&f<128||i==="latin1")&&(e=f)}}else typeof e=="number"?e=e&255:typeof e=="boolean"&&(e=Number(e));if(r<0||this.length<r||this.length<n)throw new RangeError("Out of range index");if(n<=r)return this;r=r>>>0,n=n===void 0?this.length:n>>>0,e||(e=0);let a;if(typeof e=="number")for(a=r;a<n;++a)this[a]=e;else{let f=T.isBuffer(e)?e:T.from(e,i),v=f.length;if(v===0)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(a=0;a<n-r;++a)this[a+r]=f[a%v]}return this};var Li={};function hs(t,e,r){Li[t]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:e.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${t}]`,this.stack,delete this.name}get code(){return t}set code(i){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:i,writable:!0})}toString(){return`${this.name} [${t}]: ${this.message}`}}}hs("ERR_BUFFER_OUT_OF_BOUNDS",function(t){return t?`${t} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError);hs("ERR_INVALID_ARG_TYPE",function(t,e){return`The "${t}" argument must be of type number. Received type ${typeof e}`},TypeError);hs("ERR_OUT_OF_RANGE",function(t,e,r){let n=`The value of "${t}" is out of range.`,i=r;return Number.isInteger(r)&&Math.abs(r)>2**32?i=Tl(String(r)):typeof r=="bigint"&&(i=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(i=Tl(i)),i+="n"),n+=` It must be ${e}. Received ${i}`,n},RangeError);function Tl(t){let e="",r=t.length,n=t[0]==="-"?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function y2(t,e,r){ji(e,"offset"),(t[e]===void 0||t[e+r]===void 0)&&$n(e,t.length-(r+1))}function Kl(t,e,r,n,i,a){if(t>r||t<e){let f=typeof e=="bigint"?"n":"",v;throw a>3?e===0||e===BigInt(0)?v=`>= 0${f} and < 2${f} ** ${(a+1)*8}${f}`:v=`>= -(2${f} ** ${(a+1)*8-1}${f}) and < 2 ** ${(a+1)*8-1}${f}`:v=`>= ${e}${f} and <= ${r}${f}`,new Li.ERR_OUT_OF_RANGE("value",v,t)}y2(n,i,a)}function ji(t,e){if(typeof t!="number")throw new Li.ERR_INVALID_ARG_TYPE(e,"number",t)}function $n(t,e,r){throw Math.floor(t)!==t?(ji(t,r),new Li.ERR_OUT_OF_RANGE(r||"offset","an integer",t)):e<0?new Li.ERR_BUFFER_OUT_OF_BOUNDS:new Li.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${e}`,t)}var g2=/[^+/0-9A-Za-z-_]/g;function m2(t){if(t=t.split("=")[0],t=t.trim().replace(g2,""),t.length<2)return"";for(;t.length%4!==0;)t=t+"=";return t}function fs(t,e){e=e||1/0;let r,n=t.length,i=null,a=[];for(let f=0;f<n;++f){if(r=t.charCodeAt(f),r>55295&&r<57344){if(!i){if(r>56319){(e-=3)>-1&&a.push(239,191,189);continue}else if(f+1===n){(e-=3)>-1&&a.push(239,191,189);continue}i=r;continue}if(r<56320){(e-=3)>-1&&a.push(239,191,189),i=r;continue}r=(i-55296<<10|r-56320)+65536}else i&&(e-=3)>-1&&a.push(239,191,189);if(i=null,r<128){if((e-=1)<0)break;a.push(r)}else if(r<2048){if((e-=2)<0)break;a.push(r>>6|192,r&63|128)}else if(r<65536){if((e-=3)<0)break;a.push(r>>12|224,r>>6&63|128,r&63|128)}else if(r<1114112){if((e-=4)<0)break;a.push(r>>18|240,r>>12&63|128,r>>6&63|128,r&63|128)}else throw new Error("Invalid code point")}return a}function b2(t){let e=[];for(let r=0;r<t.length;++r)e.push(t.charCodeAt(r)&255);return e}function w2(t,e){let r,n,i,a=[];for(let f=0;f<t.length&&!((e-=2)<0);++f)r=t.charCodeAt(f),n=r>>8,i=r%256,a.push(i),a.push(n);return a}function Wl(t){return ns.toByteArray(m2(t))}function Ja(t,e,r,n){let i;for(i=0;i<n&&!(i+r>=e.length||i>=t.length);++i)e[i+r]=t[i];return i}function $t(t,e){return t instanceof e||t!=null&&t.constructor!=null&&t.constructor.name!=null&&t.constructor.name===e.name}function ls(t){return t!==t}var _2=(function(){let t="0123456789abcdef",e=new Array(256);for(let r=0;r<16;++r){let n=r*16;for(let i=0;i<16;++i)e[n+i]=t[r]+t[i]}return e})();function Ir(t){return typeof BigInt>"u"?x2:t}function x2(){throw new Error("BigInt not supported")}});var S,B,w=jb(()=>{S=bl(El()),B=bl(ft())});var lr=R((zl,cs)=>{w();(function(t,e){"use strict";function r(M,h){if(!M)throw new Error(h||"Assertion failed")}function n(M,h){M.super_=h;var y=function(){};y.prototype=h.prototype,M.prototype=new y,M.prototype.constructor=M}function i(M,h,y){if(i.isBN(M))return M;this.negative=0,this.words=null,this.length=0,this.red=null,M!==null&&((h==="le"||h==="be")&&(y=h,h=10),this._init(M||0,h||10,y||"be"))}typeof t=="object"?t.exports=i:e.BN=i,i.BN=i,i.wordSize=26;var a;try{typeof window<"u"&&typeof window.Buffer<"u"?a=window.Buffer:a=ft().Buffer}catch{}i.isBN=function(h){return h instanceof i?!0:h!==null&&typeof h=="object"&&h.constructor.wordSize===i.wordSize&&Array.isArray(h.words)},i.max=function(h,y){return h.cmp(y)>0?h:y},i.min=function(h,y){return h.cmp(y)<0?h:y},i.prototype._init=function(h,y,l){if(typeof h=="number")return this._initNumber(h,y,l);if(typeof h=="object")return this._initArray(h,y,l);y==="hex"&&(y=16),r(y===(y|0)&&y>=2&&y<=36),h=h.toString().replace(/\s+/g,"");var o=0;h[0]==="-"&&(o++,this.negative=1),o<h.length&&(y===16?this._parseHex(h,o,l):(this._parseBase(h,y,o),l==="le"&&this._initArray(this.toArray(),y,l)))},i.prototype._initNumber=function(h,y,l){h<0&&(this.negative=1,h=-h),h<67108864?(this.words=[h&67108863],this.length=1):h<4503599627370496?(this.words=[h&67108863,h/67108864&67108863],this.length=2):(r(h<9007199254740992),this.words=[h&67108863,h/67108864&67108863,1],this.length=3),l==="le"&&this._initArray(this.toArray(),y,l)},i.prototype._initArray=function(h,y,l){if(r(typeof h.length=="number"),h.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(h.length/3),this.words=new Array(this.length);for(var o=0;o<this.length;o++)this.words[o]=0;var s,d,g=0;if(l==="be")for(o=h.length-1,s=0;o>=0;o-=3)d=h[o]|h[o-1]<<8|h[o-2]<<16,this.words[s]|=d<<g&67108863,this.words[s+1]=d>>>26-g&67108863,g+=24,g>=26&&(g-=26,s++);else if(l==="le")for(o=0,s=0;o<h.length;o+=3)d=h[o]|h[o+1]<<8|h[o+2]<<16,this.words[s]|=d<<g&67108863,this.words[s+1]=d>>>26-g&67108863,g+=24,g>=26&&(g-=26,s++);return this.strip()};function f(M,h){var y=M.charCodeAt(h);return y>=65&&y<=70?y-55:y>=97&&y<=102?y-87:y-48&15}function v(M,h,y){var l=f(M,y);return y-1>=h&&(l|=f(M,y-1)<<4),l}i.prototype._parseHex=function(h,y,l){this.length=Math.ceil((h.length-y)/6),this.words=new Array(this.length);for(var o=0;o<this.length;o++)this.words[o]=0;var s=0,d=0,g;if(l==="be")for(o=h.length-1;o>=y;o-=2)g=v(h,y,o)<<s,this.words[d]|=g&67108863,s>=18?(s-=18,d+=1,this.words[d]|=g>>>26):s+=8;else{var p=h.length-y;for(o=p%2===0?y+1:y;o<h.length;o+=2)g=v(h,y,o)<<s,this.words[d]|=g&67108863,s>=18?(s-=18,d+=1,this.words[d]|=g>>>26):s+=8}this.strip()};function m(M,h,y,l){for(var o=0,s=Math.min(M.length,y),d=h;d<s;d++){var g=M.charCodeAt(d)-48;o*=l,g>=49?o+=g-49+10:g>=17?o+=g-17+10:o+=g}return o}i.prototype._parseBase=function(h,y,l){this.words=[0],this.length=1;for(var o=0,s=1;s<=67108863;s*=y)o++;o--,s=s/y|0;for(var d=h.length-l,g=d%o,p=Math.min(d,d-g)+l,u=0,b=l;b<p;b+=o)u=m(h,b,b+o,y),this.imuln(s),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u);if(g!==0){var _=1;for(u=m(h,b,h.length,y),b=0;b<g;b++)_*=y;this.imuln(_),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u)}this.strip()},i.prototype.copy=function(h){h.words=new Array(this.length);for(var y=0;y<this.length;y++)h.words[y]=this.words[y];h.length=this.length,h.negative=this.negative,h.red=this.red},i.prototype.clone=function(){var h=new i(null);return this.copy(h),h},i.prototype._expand=function(h){for(;this.length<h;)this.words[this.length++]=0;return this},i.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var E=["","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"],A=[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],q=[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];i.prototype.toString=function(h,y){h=h||10,y=y|0||1;var l;if(h===16||h==="hex"){l="";for(var o=0,s=0,d=0;d<this.length;d++){var g=this.words[d],p=((g<<o|s)&16777215).toString(16);s=g>>>24-o&16777215,o+=2,o>=26&&(o-=26,d--),s!==0||d!==this.length-1?l=E[6-p.length]+p+l:l=p+l}for(s!==0&&(l=s.toString(16)+l);l.length%y!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(h===(h|0)&&h>=2&&h<=36){var u=A[h],b=q[h];l="";var _=this.clone();for(_.negative=0;!_.isZero();){var c=_.modn(b).toString(h);_=_.idivn(b),_.isZero()?l=c+l:l=E[u-c.length]+c+l}for(this.isZero()&&(l="0"+l);l.length%y!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}r(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var h=this.words[0];return this.length===2?h+=this.words[1]*67108864:this.length===3&&this.words[2]===1?h+=4503599627370496+this.words[1]*67108864:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-h:h},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(h,y){return r(typeof a<"u"),this.toArrayLike(a,h,y)},i.prototype.toArray=function(h,y){return this.toArrayLike(Array,h,y)},i.prototype.toArrayLike=function(h,y,l){var o=this.byteLength(),s=l||Math.max(1,o);r(o<=s,"byte array longer than desired length"),r(s>0,"Requested array length <= 0"),this.strip();var d=y==="le",g=new h(s),p,u,b=this.clone();if(d){for(u=0;!b.isZero();u++)p=b.andln(255),b.iushrn(8),g[u]=p;for(;u<s;u++)g[u]=0}else{for(u=0;u<s-o;u++)g[u]=0;for(u=0;!b.isZero();u++)p=b.andln(255),b.iushrn(8),g[s-u-1]=p}return g},Math.clz32?i.prototype._countBits=function(h){return 32-Math.clz32(h)}:i.prototype._countBits=function(h){var y=h,l=0;return y>=4096&&(l+=13,y>>>=13),y>=64&&(l+=7,y>>>=7),y>=8&&(l+=4,y>>>=4),y>=2&&(l+=2,y>>>=2),l+y},i.prototype._zeroBits=function(h){if(h===0)return 26;var y=h,l=0;return(y&8191)===0&&(l+=13,y>>>=13),(y&127)===0&&(l+=7,y>>>=7),(y&15)===0&&(l+=4,y>>>=4),(y&3)===0&&(l+=2,y>>>=2),(y&1)===0&&l++,l},i.prototype.bitLength=function(){var h=this.words[this.length-1],y=this._countBits(h);return(this.length-1)*26+y};function I(M){for(var h=new Array(M.bitLength()),y=0;y<h.length;y++){var l=y/26|0,o=y%26;h[y]=(M.words[l]&1<<o)>>>o}return h}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var h=0,y=0;y<this.length;y++){var l=this._zeroBits(this.words[y]);if(h+=l,l!==26)break}return h},i.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},i.prototype.toTwos=function(h){return this.negative!==0?this.abs().inotn(h).iaddn(1):this.clone()},i.prototype.fromTwos=function(h){return this.testn(h-1)?this.notn(h).iaddn(1).ineg():this.clone()},i.prototype.isNeg=function(){return this.negative!==0},i.prototype.neg=function(){return this.clone().ineg()},i.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},i.prototype.iuor=function(h){for(;this.length<h.length;)this.words[this.length++]=0;for(var y=0;y<h.length;y++)this.words[y]=this.words[y]|h.words[y];return this.strip()},i.prototype.ior=function(h){return r((this.negative|h.negative)===0),this.iuor(h)},i.prototype.or=function(h){return this.length>h.length?this.clone().ior(h):h.clone().ior(this)},i.prototype.uor=function(h){return this.length>h.length?this.clone().iuor(h):h.clone().iuor(this)},i.prototype.iuand=function(h){var y;this.length>h.length?y=h:y=this;for(var l=0;l<y.length;l++)this.words[l]=this.words[l]&h.words[l];return this.length=y.length,this.strip()},i.prototype.iand=function(h){return r((this.negative|h.negative)===0),this.iuand(h)},i.prototype.and=function(h){return this.length>h.length?this.clone().iand(h):h.clone().iand(this)},i.prototype.uand=function(h){return this.length>h.length?this.clone().iuand(h):h.clone().iuand(this)},i.prototype.iuxor=function(h){var y,l;this.length>h.length?(y=this,l=h):(y=h,l=this);for(var o=0;o<l.length;o++)this.words[o]=y.words[o]^l.words[o];if(this!==y)for(;o<y.length;o++)this.words[o]=y.words[o];return this.length=y.length,this.strip()},i.prototype.ixor=function(h){return r((this.negative|h.negative)===0),this.iuxor(h)},i.prototype.xor=function(h){return this.length>h.length?this.clone().ixor(h):h.clone().ixor(this)},i.prototype.uxor=function(h){return this.length>h.length?this.clone().iuxor(h):h.clone().iuxor(this)},i.prototype.inotn=function(h){r(typeof h=="number"&&h>=0);var y=Math.ceil(h/26)|0,l=h%26;this._expand(y),l>0&&y--;for(var o=0;o<y;o++)this.words[o]=~this.words[o]&67108863;return l>0&&(this.words[o]=~this.words[o]&67108863>>26-l),this.strip()},i.prototype.notn=function(h){return this.clone().inotn(h)},i.prototype.setn=function(h,y){r(typeof h=="number"&&h>=0);var l=h/26|0,o=h%26;return this._expand(l+1),y?this.words[l]=this.words[l]|1<<o:this.words[l]=this.words[l]&~(1<<o),this.strip()},i.prototype.iadd=function(h){var y;if(this.negative!==0&&h.negative===0)return this.negative=0,y=this.isub(h),this.negative^=1,this._normSign();if(this.negative===0&&h.negative!==0)return h.negative=0,y=this.isub(h),h.negative=1,y._normSign();var l,o;this.length>h.length?(l=this,o=h):(l=h,o=this);for(var s=0,d=0;d<o.length;d++)y=(l.words[d]|0)+(o.words[d]|0)+s,this.words[d]=y&67108863,s=y>>>26;for(;s!==0&&d<l.length;d++)y=(l.words[d]|0)+s,this.words[d]=y&67108863,s=y>>>26;if(this.length=l.length,s!==0)this.words[this.length]=s,this.length++;else if(l!==this)for(;d<l.length;d++)this.words[d]=l.words[d];return this},i.prototype.add=function(h){var y;return h.negative!==0&&this.negative===0?(h.negative=0,y=this.sub(h),h.negative^=1,y):h.negative===0&&this.negative!==0?(this.negative=0,y=h.sub(this),this.negative=1,y):this.length>h.length?this.clone().iadd(h):h.clone().iadd(this)},i.prototype.isub=function(h){if(h.negative!==0){h.negative=0;var y=this.iadd(h);return h.negative=1,y._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(h),this.negative=1,this._normSign();var l=this.cmp(h);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var o,s;l>0?(o=this,s=h):(o=h,s=this);for(var d=0,g=0;g<s.length;g++)y=(o.words[g]|0)-(s.words[g]|0)+d,d=y>>26,this.words[g]=y&67108863;for(;d!==0&&g<o.length;g++)y=(o.words[g]|0)+d,d=y>>26,this.words[g]=y&67108863;if(d===0&&g<o.length&&o!==this)for(;g<o.length;g++)this.words[g]=o.words[g];return this.length=Math.max(this.length,g),o!==this&&(this.negative=1),this.strip()},i.prototype.sub=function(h){return this.clone().isub(h)};function C(M,h,y){y.negative=h.negative^M.negative;var l=M.length+h.length|0;y.length=l,l=l-1|0;var o=M.words[0]|0,s=h.words[0]|0,d=o*s,g=d&67108863,p=d/67108864|0;y.words[0]=g;for(var u=1;u<l;u++){for(var b=p>>>26,_=p&67108863,c=Math.min(u,h.length-1),x=Math.max(0,u-M.length+1);x<=c;x++){var P=u-x|0;o=M.words[P]|0,s=h.words[x]|0,d=o*s+_,b+=d/67108864|0,_=d&67108863}y.words[u]=_|0,p=b|0}return p!==0?y.words[u]=p|0:y.length--,y.strip()}var j=function(h,y,l){var o=h.words,s=y.words,d=l.words,g=0,p,u,b,_=o[0]|0,c=_&8191,x=_>>>13,P=o[1]|0,N=P&8191,U=P>>>13,W=o[2]|0,K=W&8191,G=W>>>13,It=o[3]|0,Z=It&8191,Y=It>>>13,Tn=o[4]|0,Q=Tn&8191,ee=Tn>>>13,Cn=o[5]|0,te=Cn&8191,re=Cn>>>13,On=o[6]|0,ie=On&8191,ne=On>>>13,Pn=o[7]|0,ae=Pn&8191,oe=Pn>>>13,Dn=o[8]|0,fe=Dn&8191,se=Dn>>>13,Un=o[9]|0,ue=Un&8191,he=Un>>>13,Nn=s[0]|0,le=Nn&8191,ce=Nn>>>13,Ln=s[1]|0,de=Ln&8191,pe=Ln>>>13,Fn=s[2]|0,ve=Fn&8191,ye=Fn>>>13,jn=s[3]|0,ge=jn&8191,me=jn>>>13,Hn=s[4]|0,be=Hn&8191,we=Hn>>>13,Kn=s[5]|0,_e=Kn&8191,xe=Kn>>>13,Wn=s[6]|0,Me=Wn&8191,Ee=Wn>>>13,zn=s[7]|0,Se=zn&8191,Be=zn>>>13,Gn=s[8]|0,Ae=Gn&8191,Re=Gn>>>13,Vn=s[9]|0,qe=Vn&8191,Ie=Vn>>>13;l.negative=h.negative^y.negative,l.length=19,p=Math.imul(c,le),u=Math.imul(c,ce),u=u+Math.imul(x,le)|0,b=Math.imul(x,ce);var Ui=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Ui>>>26)|0,Ui&=67108863,p=Math.imul(N,le),u=Math.imul(N,ce),u=u+Math.imul(U,le)|0,b=Math.imul(U,ce),p=p+Math.imul(c,de)|0,u=u+Math.imul(c,pe)|0,u=u+Math.imul(x,de)|0,b=b+Math.imul(x,pe)|0;var Ge=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Ge>>>26)|0,Ge&=67108863,p=Math.imul(K,le),u=Math.imul(K,ce),u=u+Math.imul(G,le)|0,b=Math.imul(G,ce),p=p+Math.imul(N,de)|0,u=u+Math.imul(N,pe)|0,u=u+Math.imul(U,de)|0,b=b+Math.imul(U,pe)|0,p=p+Math.imul(c,ve)|0,u=u+Math.imul(c,ye)|0,u=u+Math.imul(x,ve)|0,b=b+Math.imul(x,ye)|0;var Ve=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Ve>>>26)|0,Ve&=67108863,p=Math.imul(Z,le),u=Math.imul(Z,ce),u=u+Math.imul(Y,le)|0,b=Math.imul(Y,ce),p=p+Math.imul(K,de)|0,u=u+Math.imul(K,pe)|0,u=u+Math.imul(G,de)|0,b=b+Math.imul(G,pe)|0,p=p+Math.imul(N,ve)|0,u=u+Math.imul(N,ye)|0,u=u+Math.imul(U,ve)|0,b=b+Math.imul(U,ye)|0,p=p+Math.imul(c,ge)|0,u=u+Math.imul(c,me)|0,u=u+Math.imul(x,ge)|0,b=b+Math.imul(x,me)|0;var Kr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Kr>>>26)|0,Kr&=67108863,p=Math.imul(Q,le),u=Math.imul(Q,ce),u=u+Math.imul(ee,le)|0,b=Math.imul(ee,ce),p=p+Math.imul(Z,de)|0,u=u+Math.imul(Z,pe)|0,u=u+Math.imul(Y,de)|0,b=b+Math.imul(Y,pe)|0,p=p+Math.imul(K,ve)|0,u=u+Math.imul(K,ye)|0,u=u+Math.imul(G,ve)|0,b=b+Math.imul(G,ye)|0,p=p+Math.imul(N,ge)|0,u=u+Math.imul(N,me)|0,u=u+Math.imul(U,ge)|0,b=b+Math.imul(U,me)|0,p=p+Math.imul(c,be)|0,u=u+Math.imul(c,we)|0,u=u+Math.imul(x,be)|0,b=b+Math.imul(x,we)|0;var Wr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Wr>>>26)|0,Wr&=67108863,p=Math.imul(te,le),u=Math.imul(te,ce),u=u+Math.imul(re,le)|0,b=Math.imul(re,ce),p=p+Math.imul(Q,de)|0,u=u+Math.imul(Q,pe)|0,u=u+Math.imul(ee,de)|0,b=b+Math.imul(ee,pe)|0,p=p+Math.imul(Z,ve)|0,u=u+Math.imul(Z,ye)|0,u=u+Math.imul(Y,ve)|0,b=b+Math.imul(Y,ye)|0,p=p+Math.imul(K,ge)|0,u=u+Math.imul(K,me)|0,u=u+Math.imul(G,ge)|0,b=b+Math.imul(G,me)|0,p=p+Math.imul(N,be)|0,u=u+Math.imul(N,we)|0,u=u+Math.imul(U,be)|0,b=b+Math.imul(U,we)|0,p=p+Math.imul(c,_e)|0,u=u+Math.imul(c,xe)|0,u=u+Math.imul(x,_e)|0,b=b+Math.imul(x,xe)|0;var zr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(zr>>>26)|0,zr&=67108863,p=Math.imul(ie,le),u=Math.imul(ie,ce),u=u+Math.imul(ne,le)|0,b=Math.imul(ne,ce),p=p+Math.imul(te,de)|0,u=u+Math.imul(te,pe)|0,u=u+Math.imul(re,de)|0,b=b+Math.imul(re,pe)|0,p=p+Math.imul(Q,ve)|0,u=u+Math.imul(Q,ye)|0,u=u+Math.imul(ee,ve)|0,b=b+Math.imul(ee,ye)|0,p=p+Math.imul(Z,ge)|0,u=u+Math.imul(Z,me)|0,u=u+Math.imul(Y,ge)|0,b=b+Math.imul(Y,me)|0,p=p+Math.imul(K,be)|0,u=u+Math.imul(K,we)|0,u=u+Math.imul(G,be)|0,b=b+Math.imul(G,we)|0,p=p+Math.imul(N,_e)|0,u=u+Math.imul(N,xe)|0,u=u+Math.imul(U,_e)|0,b=b+Math.imul(U,xe)|0,p=p+Math.imul(c,Me)|0,u=u+Math.imul(c,Ee)|0,u=u+Math.imul(x,Me)|0,b=b+Math.imul(x,Ee)|0;var Gr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Gr>>>26)|0,Gr&=67108863,p=Math.imul(ae,le),u=Math.imul(ae,ce),u=u+Math.imul(oe,le)|0,b=Math.imul(oe,ce),p=p+Math.imul(ie,de)|0,u=u+Math.imul(ie,pe)|0,u=u+Math.imul(ne,de)|0,b=b+Math.imul(ne,pe)|0,p=p+Math.imul(te,ve)|0,u=u+Math.imul(te,ye)|0,u=u+Math.imul(re,ve)|0,b=b+Math.imul(re,ye)|0,p=p+Math.imul(Q,ge)|0,u=u+Math.imul(Q,me)|0,u=u+Math.imul(ee,ge)|0,b=b+Math.imul(ee,me)|0,p=p+Math.imul(Z,be)|0,u=u+Math.imul(Z,we)|0,u=u+Math.imul(Y,be)|0,b=b+Math.imul(Y,we)|0,p=p+Math.imul(K,_e)|0,u=u+Math.imul(K,xe)|0,u=u+Math.imul(G,_e)|0,b=b+Math.imul(G,xe)|0,p=p+Math.imul(N,Me)|0,u=u+Math.imul(N,Ee)|0,u=u+Math.imul(U,Me)|0,b=b+Math.imul(U,Ee)|0,p=p+Math.imul(c,Se)|0,u=u+Math.imul(c,Be)|0,u=u+Math.imul(x,Se)|0,b=b+Math.imul(x,Be)|0;var Vr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Vr>>>26)|0,Vr&=67108863,p=Math.imul(fe,le),u=Math.imul(fe,ce),u=u+Math.imul(se,le)|0,b=Math.imul(se,ce),p=p+Math.imul(ae,de)|0,u=u+Math.imul(ae,pe)|0,u=u+Math.imul(oe,de)|0,b=b+Math.imul(oe,pe)|0,p=p+Math.imul(ie,ve)|0,u=u+Math.imul(ie,ye)|0,u=u+Math.imul(ne,ve)|0,b=b+Math.imul(ne,ye)|0,p=p+Math.imul(te,ge)|0,u=u+Math.imul(te,me)|0,u=u+Math.imul(re,ge)|0,b=b+Math.imul(re,me)|0,p=p+Math.imul(Q,be)|0,u=u+Math.imul(Q,we)|0,u=u+Math.imul(ee,be)|0,b=b+Math.imul(ee,we)|0,p=p+Math.imul(Z,_e)|0,u=u+Math.imul(Z,xe)|0,u=u+Math.imul(Y,_e)|0,b=b+Math.imul(Y,xe)|0,p=p+Math.imul(K,Me)|0,u=u+Math.imul(K,Ee)|0,u=u+Math.imul(G,Me)|0,b=b+Math.imul(G,Ee)|0,p=p+Math.imul(N,Se)|0,u=u+Math.imul(N,Be)|0,u=u+Math.imul(U,Se)|0,b=b+Math.imul(U,Be)|0,p=p+Math.imul(c,Ae)|0,u=u+Math.imul(c,Re)|0,u=u+Math.imul(x,Ae)|0,b=b+Math.imul(x,Re)|0;var $r=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+($r>>>26)|0,$r&=67108863,p=Math.imul(ue,le),u=Math.imul(ue,ce),u=u+Math.imul(he,le)|0,b=Math.imul(he,ce),p=p+Math.imul(fe,de)|0,u=u+Math.imul(fe,pe)|0,u=u+Math.imul(se,de)|0,b=b+Math.imul(se,pe)|0,p=p+Math.imul(ae,ve)|0,u=u+Math.imul(ae,ye)|0,u=u+Math.imul(oe,ve)|0,b=b+Math.imul(oe,ye)|0,p=p+Math.imul(ie,ge)|0,u=u+Math.imul(ie,me)|0,u=u+Math.imul(ne,ge)|0,b=b+Math.imul(ne,me)|0,p=p+Math.imul(te,be)|0,u=u+Math.imul(te,we)|0,u=u+Math.imul(re,be)|0,b=b+Math.imul(re,we)|0,p=p+Math.imul(Q,_e)|0,u=u+Math.imul(Q,xe)|0,u=u+Math.imul(ee,_e)|0,b=b+Math.imul(ee,xe)|0,p=p+Math.imul(Z,Me)|0,u=u+Math.imul(Z,Ee)|0,u=u+Math.imul(Y,Me)|0,b=b+Math.imul(Y,Ee)|0,p=p+Math.imul(K,Se)|0,u=u+Math.imul(K,Be)|0,u=u+Math.imul(G,Se)|0,b=b+Math.imul(G,Be)|0,p=p+Math.imul(N,Ae)|0,u=u+Math.imul(N,Re)|0,u=u+Math.imul(U,Ae)|0,b=b+Math.imul(U,Re)|0,p=p+Math.imul(c,qe)|0,u=u+Math.imul(c,Ie)|0,u=u+Math.imul(x,qe)|0,b=b+Math.imul(x,Ie)|0;var Zr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Zr>>>26)|0,Zr&=67108863,p=Math.imul(ue,de),u=Math.imul(ue,pe),u=u+Math.imul(he,de)|0,b=Math.imul(he,pe),p=p+Math.imul(fe,ve)|0,u=u+Math.imul(fe,ye)|0,u=u+Math.imul(se,ve)|0,b=b+Math.imul(se,ye)|0,p=p+Math.imul(ae,ge)|0,u=u+Math.imul(ae,me)|0,u=u+Math.imul(oe,ge)|0,b=b+Math.imul(oe,me)|0,p=p+Math.imul(ie,be)|0,u=u+Math.imul(ie,we)|0,u=u+Math.imul(ne,be)|0,b=b+Math.imul(ne,we)|0,p=p+Math.imul(te,_e)|0,u=u+Math.imul(te,xe)|0,u=u+Math.imul(re,_e)|0,b=b+Math.imul(re,xe)|0,p=p+Math.imul(Q,Me)|0,u=u+Math.imul(Q,Ee)|0,u=u+Math.imul(ee,Me)|0,b=b+Math.imul(ee,Ee)|0,p=p+Math.imul(Z,Se)|0,u=u+Math.imul(Z,Be)|0,u=u+Math.imul(Y,Se)|0,b=b+Math.imul(Y,Be)|0,p=p+Math.imul(K,Ae)|0,u=u+Math.imul(K,Re)|0,u=u+Math.imul(G,Ae)|0,b=b+Math.imul(G,Re)|0,p=p+Math.imul(N,qe)|0,u=u+Math.imul(N,Ie)|0,u=u+Math.imul(U,qe)|0,b=b+Math.imul(U,Ie)|0;var Yr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Yr>>>26)|0,Yr&=67108863,p=Math.imul(ue,ve),u=Math.imul(ue,ye),u=u+Math.imul(he,ve)|0,b=Math.imul(he,ye),p=p+Math.imul(fe,ge)|0,u=u+Math.imul(fe,me)|0,u=u+Math.imul(se,ge)|0,b=b+Math.imul(se,me)|0,p=p+Math.imul(ae,be)|0,u=u+Math.imul(ae,we)|0,u=u+Math.imul(oe,be)|0,b=b+Math.imul(oe,we)|0,p=p+Math.imul(ie,_e)|0,u=u+Math.imul(ie,xe)|0,u=u+Math.imul(ne,_e)|0,b=b+Math.imul(ne,xe)|0,p=p+Math.imul(te,Me)|0,u=u+Math.imul(te,Ee)|0,u=u+Math.imul(re,Me)|0,b=b+Math.imul(re,Ee)|0,p=p+Math.imul(Q,Se)|0,u=u+Math.imul(Q,Be)|0,u=u+Math.imul(ee,Se)|0,b=b+Math.imul(ee,Be)|0,p=p+Math.imul(Z,Ae)|0,u=u+Math.imul(Z,Re)|0,u=u+Math.imul(Y,Ae)|0,b=b+Math.imul(Y,Re)|0,p=p+Math.imul(K,qe)|0,u=u+Math.imul(K,Ie)|0,u=u+Math.imul(G,qe)|0,b=b+Math.imul(G,Ie)|0;var Xr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Xr>>>26)|0,Xr&=67108863,p=Math.imul(ue,ge),u=Math.imul(ue,me),u=u+Math.imul(he,ge)|0,b=Math.imul(he,me),p=p+Math.imul(fe,be)|0,u=u+Math.imul(fe,we)|0,u=u+Math.imul(se,be)|0,b=b+Math.imul(se,we)|0,p=p+Math.imul(ae,_e)|0,u=u+Math.imul(ae,xe)|0,u=u+Math.imul(oe,_e)|0,b=b+Math.imul(oe,xe)|0,p=p+Math.imul(ie,Me)|0,u=u+Math.imul(ie,Ee)|0,u=u+Math.imul(ne,Me)|0,b=b+Math.imul(ne,Ee)|0,p=p+Math.imul(te,Se)|0,u=u+Math.imul(te,Be)|0,u=u+Math.imul(re,Se)|0,b=b+Math.imul(re,Be)|0,p=p+Math.imul(Q,Ae)|0,u=u+Math.imul(Q,Re)|0,u=u+Math.imul(ee,Ae)|0,b=b+Math.imul(ee,Re)|0,p=p+Math.imul(Z,qe)|0,u=u+Math.imul(Z,Ie)|0,u=u+Math.imul(Y,qe)|0,b=b+Math.imul(Y,Ie)|0;var Jr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Jr>>>26)|0,Jr&=67108863,p=Math.imul(ue,be),u=Math.imul(ue,we),u=u+Math.imul(he,be)|0,b=Math.imul(he,we),p=p+Math.imul(fe,_e)|0,u=u+Math.imul(fe,xe)|0,u=u+Math.imul(se,_e)|0,b=b+Math.imul(se,xe)|0,p=p+Math.imul(ae,Me)|0,u=u+Math.imul(ae,Ee)|0,u=u+Math.imul(oe,Me)|0,b=b+Math.imul(oe,Ee)|0,p=p+Math.imul(ie,Se)|0,u=u+Math.imul(ie,Be)|0,u=u+Math.imul(ne,Se)|0,b=b+Math.imul(ne,Be)|0,p=p+Math.imul(te,Ae)|0,u=u+Math.imul(te,Re)|0,u=u+Math.imul(re,Ae)|0,b=b+Math.imul(re,Re)|0,p=p+Math.imul(Q,qe)|0,u=u+Math.imul(Q,Ie)|0,u=u+Math.imul(ee,qe)|0,b=b+Math.imul(ee,Ie)|0;var Qr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Qr>>>26)|0,Qr&=67108863,p=Math.imul(ue,_e),u=Math.imul(ue,xe),u=u+Math.imul(he,_e)|0,b=Math.imul(he,xe),p=p+Math.imul(fe,Me)|0,u=u+Math.imul(fe,Ee)|0,u=u+Math.imul(se,Me)|0,b=b+Math.imul(se,Ee)|0,p=p+Math.imul(ae,Se)|0,u=u+Math.imul(ae,Be)|0,u=u+Math.imul(oe,Se)|0,b=b+Math.imul(oe,Be)|0,p=p+Math.imul(ie,Ae)|0,u=u+Math.imul(ie,Re)|0,u=u+Math.imul(ne,Ae)|0,b=b+Math.imul(ne,Re)|0,p=p+Math.imul(te,qe)|0,u=u+Math.imul(te,Ie)|0,u=u+Math.imul(re,qe)|0,b=b+Math.imul(re,Ie)|0;var ei=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ei>>>26)|0,ei&=67108863,p=Math.imul(ue,Me),u=Math.imul(ue,Ee),u=u+Math.imul(he,Me)|0,b=Math.imul(he,Ee),p=p+Math.imul(fe,Se)|0,u=u+Math.imul(fe,Be)|0,u=u+Math.imul(se,Se)|0,b=b+Math.imul(se,Be)|0,p=p+Math.imul(ae,Ae)|0,u=u+Math.imul(ae,Re)|0,u=u+Math.imul(oe,Ae)|0,b=b+Math.imul(oe,Re)|0,p=p+Math.imul(ie,qe)|0,u=u+Math.imul(ie,Ie)|0,u=u+Math.imul(ne,qe)|0,b=b+Math.imul(ne,Ie)|0;var ti=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ti>>>26)|0,ti&=67108863,p=Math.imul(ue,Se),u=Math.imul(ue,Be),u=u+Math.imul(he,Se)|0,b=Math.imul(he,Be),p=p+Math.imul(fe,Ae)|0,u=u+Math.imul(fe,Re)|0,u=u+Math.imul(se,Ae)|0,b=b+Math.imul(se,Re)|0,p=p+Math.imul(ae,qe)|0,u=u+Math.imul(ae,Ie)|0,u=u+Math.imul(oe,qe)|0,b=b+Math.imul(oe,Ie)|0;var ri=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ri>>>26)|0,ri&=67108863,p=Math.imul(ue,Ae),u=Math.imul(ue,Re),u=u+Math.imul(he,Ae)|0,b=Math.imul(he,Re),p=p+Math.imul(fe,qe)|0,u=u+Math.imul(fe,Ie)|0,u=u+Math.imul(se,qe)|0,b=b+Math.imul(se,Ie)|0;var ii=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ii>>>26)|0,ii&=67108863,p=Math.imul(ue,qe),u=Math.imul(ue,Ie),u=u+Math.imul(he,qe)|0,b=Math.imul(he,Ie);var ni=(g+p|0)+((u&8191)<<13)|0;return g=(b+(u>>>13)|0)+(ni>>>26)|0,ni&=67108863,d[0]=Ui,d[1]=Ge,d[2]=Ve,d[3]=Kr,d[4]=Wr,d[5]=zr,d[6]=Gr,d[7]=Vr,d[8]=$r,d[9]=Zr,d[10]=Yr,d[11]=Xr,d[12]=Jr,d[13]=Qr,d[14]=ei,d[15]=ti,d[16]=ri,d[17]=ii,d[18]=ni,g!==0&&(d[19]=g,l.length++),l};Math.imul||(j=C);function V(M,h,y){y.negative=h.negative^M.negative,y.length=M.length+h.length;for(var l=0,o=0,s=0;s<y.length-1;s++){var d=o;o=0;for(var g=l&67108863,p=Math.min(s,h.length-1),u=Math.max(0,s-M.length+1);u<=p;u++){var b=s-u,_=M.words[b]|0,c=h.words[u]|0,x=_*c,P=x&67108863;d=d+(x/67108864|0)|0,P=P+g|0,g=P&67108863,d=d+(P>>>26)|0,o+=d>>>26,d&=67108863}y.words[s]=g,l=d,d=o}return l!==0?y.words[s]=l:y.length--,y.strip()}function X(M,h,y){var l=new z;return l.mulp(M,h,y)}i.prototype.mulTo=function(h,y){var l,o=this.length+h.length;return this.length===10&&h.length===10?l=j(this,h,y):o<63?l=C(this,h,y):o<1024?l=V(this,h,y):l=X(this,h,y),l};function z(M,h){this.x=M,this.y=h}z.prototype.makeRBT=function(h){for(var y=new Array(h),l=i.prototype._countBits(h)-1,o=0;o<h;o++)y[o]=this.revBin(o,l,h);return y},z.prototype.revBin=function(h,y,l){if(h===0||h===l-1)return h;for(var o=0,s=0;s<y;s++)o|=(h&1)<<y-s-1,h>>=1;return o},z.prototype.permute=function(h,y,l,o,s,d){for(var g=0;g<d;g++)o[g]=y[h[g]],s[g]=l[h[g]]},z.prototype.transform=function(h,y,l,o,s,d){this.permute(d,h,y,l,o,s);for(var g=1;g<s;g<<=1)for(var p=g<<1,u=Math.cos(2*Math.PI/p),b=Math.sin(2*Math.PI/p),_=0;_<s;_+=p)for(var c=u,x=b,P=0;P<g;P++){var N=l[_+P],U=o[_+P],W=l[_+P+g],K=o[_+P+g],G=c*W-x*K;K=c*K+x*W,W=G,l[_+P]=N+W,o[_+P]=U+K,l[_+P+g]=N-W,o[_+P+g]=U-K,P!==p&&(G=u*c-b*x,x=u*x+b*c,c=G)}},z.prototype.guessLen13b=function(h,y){var l=Math.max(y,h)|1,o=l&1,s=0;for(l=l/2|0;l;l=l>>>1)s++;return 1<<s+1+o},z.prototype.conjugate=function(h,y,l){if(!(l<=1))for(var o=0;o<l/2;o++){var s=h[o];h[o]=h[l-o-1],h[l-o-1]=s,s=y[o],y[o]=-y[l-o-1],y[l-o-1]=-s}},z.prototype.normalize13b=function(h,y){for(var l=0,o=0;o<y/2;o++){var s=Math.round(h[2*o+1]/y)*8192+Math.round(h[2*o]/y)+l;h[o]=s&67108863,s<67108864?l=0:l=s/67108864|0}return h},z.prototype.convert13b=function(h,y,l,o){for(var s=0,d=0;d<y;d++)s=s+(h[d]|0),l[2*d]=s&8191,s=s>>>13,l[2*d+1]=s&8191,s=s>>>13;for(d=2*y;d<o;++d)l[d]=0;r(s===0),r((s&-8192)===0)},z.prototype.stub=function(h){for(var y=new Array(h),l=0;l<h;l++)y[l]=0;return y},z.prototype.mulp=function(h,y,l){var o=2*this.guessLen13b(h.length,y.length),s=this.makeRBT(o),d=this.stub(o),g=new Array(o),p=new Array(o),u=new Array(o),b=new Array(o),_=new Array(o),c=new Array(o),x=l.words;x.length=o,this.convert13b(h.words,h.length,g,o),this.convert13b(y.words,y.length,b,o),this.transform(g,d,p,u,o,s),this.transform(b,d,_,c,o,s);for(var P=0;P<o;P++){var N=p[P]*_[P]-u[P]*c[P];u[P]=p[P]*c[P]+u[P]*_[P],p[P]=N}return this.conjugate(p,u,o),this.transform(p,u,x,d,o,s),this.conjugate(x,d,o),this.normalize13b(x,o),l.negative=h.negative^y.negative,l.length=h.length+y.length,l.strip()},i.prototype.mul=function(h){var y=new i(null);return y.words=new Array(this.length+h.length),this.mulTo(h,y)},i.prototype.mulf=function(h){var y=new i(null);return y.words=new Array(this.length+h.length),X(this,h,y)},i.prototype.imul=function(h){return this.clone().mulTo(h,this)},i.prototype.imuln=function(h){r(typeof h=="number"),r(h<67108864);for(var y=0,l=0;l<this.length;l++){var o=(this.words[l]|0)*h,s=(o&67108863)+(y&67108863);y>>=26,y+=o/67108864|0,y+=s>>>26,this.words[l]=s&67108863}return y!==0&&(this.words[l]=y,this.length++),this.length=h===0?1:this.length,this},i.prototype.muln=function(h){return this.clone().imuln(h)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(h){var y=I(h);if(y.length===0)return new i(1);for(var l=this,o=0;o<y.length&&y[o]===0;o++,l=l.sqr());if(++o<y.length)for(var s=l.sqr();o<y.length;o++,s=s.sqr())y[o]!==0&&(l=l.mul(s));return l},i.prototype.iushln=function(h){r(typeof h=="number"&&h>=0);var y=h%26,l=(h-y)/26,o=67108863>>>26-y<<26-y,s;if(y!==0){var d=0;for(s=0;s<this.length;s++){var g=this.words[s]&o,p=(this.words[s]|0)-g<<y;this.words[s]=p|d,d=g>>>26-y}d&&(this.words[s]=d,this.length++)}if(l!==0){for(s=this.length-1;s>=0;s--)this.words[s+l]=this.words[s];for(s=0;s<l;s++)this.words[s]=0;this.length+=l}return this.strip()},i.prototype.ishln=function(h){return r(this.negative===0),this.iushln(h)},i.prototype.iushrn=function(h,y,l){r(typeof h=="number"&&h>=0);var o;y?o=(y-y%26)/26:o=0;var s=h%26,d=Math.min((h-s)/26,this.length),g=67108863^67108863>>>s<<s,p=l;if(o-=d,o=Math.max(0,o),p){for(var u=0;u<d;u++)p.words[u]=this.words[u];p.length=d}if(d!==0)if(this.length>d)for(this.length-=d,u=0;u<this.length;u++)this.words[u]=this.words[u+d];else this.words[0]=0,this.length=1;var b=0;for(u=this.length-1;u>=0&&(b!==0||u>=o);u--){var _=this.words[u]|0;this.words[u]=b<<26-s|_>>>s,b=_&g}return p&&b!==0&&(p.words[p.length++]=b),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(h,y,l){return r(this.negative===0),this.iushrn(h,y,l)},i.prototype.shln=function(h){return this.clone().ishln(h)},i.prototype.ushln=function(h){return this.clone().iushln(h)},i.prototype.shrn=function(h){return this.clone().ishrn(h)},i.prototype.ushrn=function(h){return this.clone().iushrn(h)},i.prototype.testn=function(h){r(typeof h=="number"&&h>=0);var y=h%26,l=(h-y)/26,o=1<<y;if(this.length<=l)return!1;var s=this.words[l];return!!(s&o)},i.prototype.imaskn=function(h){r(typeof h=="number"&&h>=0);var y=h%26,l=(h-y)/26;if(r(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(y!==0&&l++,this.length=Math.min(l,this.length),y!==0){var o=67108863^67108863>>>y<<y;this.words[this.length-1]&=o}return this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.maskn=function(h){return this.clone().imaskn(h)},i.prototype.iaddn=function(h){return r(typeof h=="number"),r(h<67108864),h<0?this.isubn(-h):this.negative!==0?this.length===1&&(this.words[0]|0)<h?(this.words[0]=h-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(h),this.negative=1,this):this._iaddn(h)},i.prototype._iaddn=function(h){this.words[0]+=h;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},i.prototype.isubn=function(h){if(r(typeof h=="number"),r(h<67108864),h<0)return this.iaddn(-h);if(this.negative!==0)return this.negative=0,this.iaddn(h),this.negative=1,this;if(this.words[0]-=h,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()},i.prototype.addn=function(h){return this.clone().iaddn(h)},i.prototype.subn=function(h){return this.clone().isubn(h)},i.prototype.iabs=function(){return this.negative=0,this},i.prototype.abs=function(){return this.clone().iabs()},i.prototype._ishlnsubmul=function(h,y,l){var o=h.length+l,s;this._expand(o);var d,g=0;for(s=0;s<h.length;s++){d=(this.words[s+l]|0)+g;var p=(h.words[s]|0)*y;d-=p&67108863,g=(d>>26)-(p/67108864|0),this.words[s+l]=d&67108863}for(;s<this.length-l;s++)d=(this.words[s+l]|0)+g,g=d>>26,this.words[s+l]=d&67108863;if(g===0)return this.strip();for(r(g===-1),g=0,s=0;s<this.length;s++)d=-(this.words[s]|0)+g,g=d>>26,this.words[s]=d&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(h,y){var l=this.length-h.length,o=this.clone(),s=h,d=s.words[s.length-1]|0,g=this._countBits(d);l=26-g,l!==0&&(s=s.ushln(l),o.iushln(l),d=s.words[s.length-1]|0);var p=o.length-s.length,u;if(y!=="mod"){u=new i(null),u.length=p+1,u.words=new Array(u.length);for(var b=0;b<u.length;b++)u.words[b]=0}var _=o.clone()._ishlnsubmul(s,1,p);_.negative===0&&(o=_,u&&(u.words[p]=1));for(var c=p-1;c>=0;c--){var x=(o.words[s.length+c]|0)*67108864+(o.words[s.length+c-1]|0);for(x=Math.min(x/d|0,67108863),o._ishlnsubmul(s,x,c);o.negative!==0;)x--,o.negative=0,o._ishlnsubmul(s,1,c),o.isZero()||(o.negative^=1);u&&(u.words[c]=x)}return u&&u.strip(),o.strip(),y!=="div"&&l!==0&&o.iushrn(l),{div:u||null,mod:o}},i.prototype.divmod=function(h,y,l){if(r(!h.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var o,s,d;return this.negative!==0&&h.negative===0?(d=this.neg().divmod(h,y),y!=="mod"&&(o=d.div.neg()),y!=="div"&&(s=d.mod.neg(),l&&s.negative!==0&&s.iadd(h)),{div:o,mod:s}):this.negative===0&&h.negative!==0?(d=this.divmod(h.neg(),y),y!=="mod"&&(o=d.div.neg()),{div:o,mod:d.mod}):(this.negative&h.negative)!==0?(d=this.neg().divmod(h.neg(),y),y!=="div"&&(s=d.mod.neg(),l&&s.negative!==0&&s.isub(h)),{div:d.div,mod:s}):h.length>this.length||this.cmp(h)<0?{div:new i(0),mod:this}:h.length===1?y==="div"?{div:this.divn(h.words[0]),mod:null}:y==="mod"?{div:null,mod:new i(this.modn(h.words[0]))}:{div:this.divn(h.words[0]),mod:new i(this.modn(h.words[0]))}:this._wordDiv(h,y)},i.prototype.div=function(h){return this.divmod(h,"div",!1).div},i.prototype.mod=function(h){return this.divmod(h,"mod",!1).mod},i.prototype.umod=function(h){return this.divmod(h,"mod",!0).mod},i.prototype.divRound=function(h){var y=this.divmod(h);if(y.mod.isZero())return y.div;var l=y.div.negative!==0?y.mod.isub(h):y.mod,o=h.ushrn(1),s=h.andln(1),d=l.cmp(o);return d<0||s===1&&d===0?y.div:y.div.negative!==0?y.div.isubn(1):y.div.iaddn(1)},i.prototype.modn=function(h){r(h<=67108863);for(var y=(1<<26)%h,l=0,o=this.length-1;o>=0;o--)l=(y*l+(this.words[o]|0))%h;return l},i.prototype.idivn=function(h){r(h<=67108863);for(var y=0,l=this.length-1;l>=0;l--){var o=(this.words[l]|0)+y*67108864;this.words[l]=o/h|0,y=o%h}return this.strip()},i.prototype.divn=function(h){return this.clone().idivn(h)},i.prototype.egcd=function(h){r(h.negative===0),r(!h.isZero());var y=this,l=h.clone();y.negative!==0?y=y.umod(h):y=y.clone();for(var o=new i(1),s=new i(0),d=new i(0),g=new i(1),p=0;y.isEven()&&l.isEven();)y.iushrn(1),l.iushrn(1),++p;for(var u=l.clone(),b=y.clone();!y.isZero();){for(var _=0,c=1;(y.words[0]&c)===0&&_<26;++_,c<<=1);if(_>0)for(y.iushrn(_);_-- >0;)(o.isOdd()||s.isOdd())&&(o.iadd(u),s.isub(b)),o.iushrn(1),s.iushrn(1);for(var x=0,P=1;(l.words[0]&P)===0&&x<26;++x,P<<=1);if(x>0)for(l.iushrn(x);x-- >0;)(d.isOdd()||g.isOdd())&&(d.iadd(u),g.isub(b)),d.iushrn(1),g.iushrn(1);y.cmp(l)>=0?(y.isub(l),o.isub(d),s.isub(g)):(l.isub(y),d.isub(o),g.isub(s))}return{a:d,b:g,gcd:l.iushln(p)}},i.prototype._invmp=function(h){r(h.negative===0),r(!h.isZero());var y=this,l=h.clone();y.negative!==0?y=y.umod(h):y=y.clone();for(var o=new i(1),s=new i(0),d=l.clone();y.cmpn(1)>0&&l.cmpn(1)>0;){for(var g=0,p=1;(y.words[0]&p)===0&&g<26;++g,p<<=1);if(g>0)for(y.iushrn(g);g-- >0;)o.isOdd()&&o.iadd(d),o.iushrn(1);for(var u=0,b=1;(l.words[0]&b)===0&&u<26;++u,b<<=1);if(u>0)for(l.iushrn(u);u-- >0;)s.isOdd()&&s.iadd(d),s.iushrn(1);y.cmp(l)>=0?(y.isub(l),o.isub(s)):(l.isub(y),s.isub(o))}var _;return y.cmpn(1)===0?_=o:_=s,_.cmpn(0)<0&&_.iadd(h),_},i.prototype.gcd=function(h){if(this.isZero())return h.abs();if(h.isZero())return this.abs();var y=this.clone(),l=h.clone();y.negative=0,l.negative=0;for(var o=0;y.isEven()&&l.isEven();o++)y.iushrn(1),l.iushrn(1);do{for(;y.isEven();)y.iushrn(1);for(;l.isEven();)l.iushrn(1);var s=y.cmp(l);if(s<0){var d=y;y=l,l=d}else if(s===0||l.cmpn(1)===0)break;y.isub(l)}while(!0);return l.iushln(o)},i.prototype.invm=function(h){return this.egcd(h).a.umod(h)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(h){return this.words[0]&h},i.prototype.bincn=function(h){r(typeof h=="number");var y=h%26,l=(h-y)/26,o=1<<y;if(this.length<=l)return this._expand(l+1),this.words[l]|=o,this;for(var s=o,d=l;s!==0&&d<this.length;d++){var g=this.words[d]|0;g+=s,s=g>>>26,g&=67108863,this.words[d]=g}return s!==0&&(this.words[d]=s,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(h){var y=h<0;if(this.negative!==0&&!y)return-1;if(this.negative===0&&y)return 1;this.strip();var l;if(this.length>1)l=1;else{y&&(h=-h),r(h<=67108863,"Number is too big");var o=this.words[0]|0;l=o===h?0:o<h?-1:1}return this.negative!==0?-l|0:l},i.prototype.cmp=function(h){if(this.negative!==0&&h.negative===0)return-1;if(this.negative===0&&h.negative!==0)return 1;var y=this.ucmp(h);return this.negative!==0?-y|0:y},i.prototype.ucmp=function(h){if(this.length>h.length)return 1;if(this.length<h.length)return-1;for(var y=0,l=this.length-1;l>=0;l--){var o=this.words[l]|0,s=h.words[l]|0;if(o!==s){o<s?y=-1:o>s&&(y=1);break}}return y},i.prototype.gtn=function(h){return this.cmpn(h)===1},i.prototype.gt=function(h){return this.cmp(h)===1},i.prototype.gten=function(h){return this.cmpn(h)>=0},i.prototype.gte=function(h){return this.cmp(h)>=0},i.prototype.ltn=function(h){return this.cmpn(h)===-1},i.prototype.lt=function(h){return this.cmp(h)===-1},i.prototype.lten=function(h){return this.cmpn(h)<=0},i.prototype.lte=function(h){return this.cmp(h)<=0},i.prototype.eqn=function(h){return this.cmpn(h)===0},i.prototype.eq=function(h){return this.cmp(h)===0},i.red=function(h){return new F(h)},i.prototype.toRed=function(h){return r(!this.red,"Already a number in reduction context"),r(this.negative===0,"red works only with positives"),h.convertTo(this)._forceRed(h)},i.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(h){return this.red=h,this},i.prototype.forceRed=function(h){return r(!this.red,"Already a number in reduction context"),this._forceRed(h)},i.prototype.redAdd=function(h){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,h)},i.prototype.redIAdd=function(h){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,h)},i.prototype.redSub=function(h){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,h)},i.prototype.redISub=function(h){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,h)},i.prototype.redShl=function(h){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,h)},i.prototype.redMul=function(h){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,h),this.red.mul(this,h)},i.prototype.redIMul=function(h){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,h),this.red.imul(this,h)},i.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(h){return r(this.red&&!h.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,h)};var $={k256:null,p224:null,p192:null,p25519:null};function Fe(M,h){this.name=M,this.p=new i(h,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Fe.prototype._tmp=function(){var h=new i(null);return h.words=new Array(Math.ceil(this.n/13)),h},Fe.prototype.ireduce=function(h){var y=h,l;do this.split(y,this.tmp),y=this.imulK(y),y=y.iadd(this.tmp),l=y.bitLength();while(l>this.n);var o=l<this.n?-1:y.ucmp(this.p);return o===0?(y.words[0]=0,y.length=1):o>0?y.isub(this.p):y.strip!==void 0?y.strip():y._strip(),y},Fe.prototype.split=function(h,y){h.iushrn(this.n,0,y)},Fe.prototype.imulK=function(h){return h.imul(this.k)};function k(){Fe.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}n(k,Fe),k.prototype.split=function(h,y){for(var l=4194303,o=Math.min(h.length,9),s=0;s<o;s++)y.words[s]=h.words[s];if(y.length=o,h.length<=9){h.words[0]=0,h.length=1;return}var d=h.words[9];for(y.words[y.length++]=d&l,s=10;s<h.length;s++){var g=h.words[s]|0;h.words[s-10]=(g&l)<<4|d>>>22,d=g}d>>>=22,h.words[s-10]=d,d===0&&h.length>10?h.length-=10:h.length-=9},k.prototype.imulK=function(h){h.words[h.length]=0,h.words[h.length+1]=0,h.length+=2;for(var y=0,l=0;l<h.length;l++){var o=h.words[l]|0;y+=o*977,h.words[l]=y&67108863,y=o*64+(y/67108864|0)}return h.words[h.length-1]===0&&(h.length--,h.words[h.length-1]===0&&h.length--),h};function O(){Fe.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}n(O,Fe);function D(){Fe.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}n(D,Fe);function L(){Fe.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}n(L,Fe),L.prototype.imulK=function(h){for(var y=0,l=0;l<h.length;l++){var o=(h.words[l]|0)*19+y,s=o&67108863;o>>>=26,h.words[l]=s,y=o}return y!==0&&(h.words[h.length++]=y),h},i._prime=function(h){if($[h])return $[h];var y;if(h==="k256")y=new k;else if(h==="p224")y=new O;else if(h==="p192")y=new D;else if(h==="p25519")y=new L;else throw new Error("Unknown prime "+h);return $[h]=y,y};function F(M){if(typeof M=="string"){var h=i._prime(M);this.m=h.p,this.prime=h}else r(M.gtn(1),"modulus must be greater than 1"),this.m=M,this.prime=null}F.prototype._verify1=function(h){r(h.negative===0,"red works only with positives"),r(h.red,"red works only with red numbers")},F.prototype._verify2=function(h,y){r((h.negative|y.negative)===0,"red works only with positives"),r(h.red&&h.red===y.red,"red works only with red numbers")},F.prototype.imod=function(h){return this.prime?this.prime.ireduce(h)._forceRed(this):h.umod(this.m)._forceRed(this)},F.prototype.neg=function(h){return h.isZero()?h.clone():this.m.sub(h)._forceRed(this)},F.prototype.add=function(h,y){this._verify2(h,y);var l=h.add(y);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},F.prototype.iadd=function(h,y){this._verify2(h,y);var l=h.iadd(y);return l.cmp(this.m)>=0&&l.isub(this.m),l},F.prototype.sub=function(h,y){this._verify2(h,y);var l=h.sub(y);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},F.prototype.isub=function(h,y){this._verify2(h,y);var l=h.isub(y);return l.cmpn(0)<0&&l.iadd(this.m),l},F.prototype.shl=function(h,y){return this._verify1(h),this.imod(h.ushln(y))},F.prototype.imul=function(h,y){return this._verify2(h,y),this.imod(h.imul(y))},F.prototype.mul=function(h,y){return this._verify2(h,y),this.imod(h.mul(y))},F.prototype.isqr=function(h){return this.imul(h,h.clone())},F.prototype.sqr=function(h){return this.mul(h,h)},F.prototype.sqrt=function(h){if(h.isZero())return h.clone();var y=this.m.andln(3);if(r(y%2===1),y===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(h,l)}for(var o=this.m.subn(1),s=0;!o.isZero()&&o.andln(1)===0;)s++,o.iushrn(1);r(!o.isZero());var d=new i(1).toRed(this),g=d.redNeg(),p=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new i(2*u*u).toRed(this);this.pow(u,p).cmp(g)!==0;)u.redIAdd(g);for(var b=this.pow(u,o),_=this.pow(h,o.addn(1).iushrn(1)),c=this.pow(h,o),x=s;c.cmp(d)!==0;){for(var P=c,N=0;P.cmp(d)!==0;N++)P=P.redSqr();r(N<x);var U=this.pow(b,new i(1).iushln(x-N-1));_=_.redMul(U),b=U.redSqr(),c=c.redMul(b),x=N}return _},F.prototype.invm=function(h){var y=h._invmp(this.m);return y.negative!==0?(y.negative=0,this.imod(y).redNeg()):this.imod(y)},F.prototype.pow=function(h,y){if(y.isZero())return new i(1).toRed(this);if(y.cmpn(1)===0)return h.clone();var l=4,o=new Array(1<<l);o[0]=new i(1).toRed(this),o[1]=h;for(var s=2;s<o.length;s++)o[s]=this.mul(o[s-1],h);var d=o[0],g=0,p=0,u=y.bitLength()%26;for(u===0&&(u=26),s=y.length-1;s>=0;s--){for(var b=y.words[s],_=u-1;_>=0;_--){var c=b>>_&1;if(d!==o[0]&&(d=this.sqr(d)),c===0&&g===0){p=0;continue}g<<=1,g|=c,p++,!(p!==l&&(s!==0||_!==0))&&(d=this.mul(d,o[g]),p=0,g=0)}u=26}return d},F.prototype.convertTo=function(h){var y=h.umod(this.m);return y===h?y.clone():y},F.prototype.convertFrom=function(h){var y=h.clone();return y.red=null,y},i.mont=function(h){return new H(h)};function H(M){F.call(this,M),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(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)}n(H,F),H.prototype.convertTo=function(h){return this.imod(h.ushln(this.shift))},H.prototype.convertFrom=function(h){var y=this.imod(h.mul(this.rinv));return y.red=null,y},H.prototype.imul=function(h,y){if(h.isZero()||y.isZero())return h.words[0]=0,h.length=1,h;var l=h.imul(y),o=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),s=l.isub(o).iushrn(this.shift),d=s;return s.cmp(this.m)>=0?d=s.isub(this.m):s.cmpn(0)<0&&(d=s.iadd(this.m)),d._forceRed(this)},H.prototype.mul=function(h,y){if(h.isZero()||y.isZero())return new i(0)._forceRed(this);var l=h.mul(y),o=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),s=l.isub(o).iushrn(this.shift),d=s;return s.cmp(this.m)>=0?d=s.isub(this.m):s.cmpn(0)<0&&(d=s.iadd(this.m)),d._forceRed(this)},H.prototype.invm=function(h){var y=this.imod(h._invmp(this.m).mul(this.r2));return y._forceRed(this)}})(typeof cs>"u"||cs,zl)});var ke=R((ds,Vl)=>{w();var Qa=ft(),Zt=Qa.Buffer;function Gl(t,e){for(var r in t)e[r]=t[r]}Zt.from&&Zt.alloc&&Zt.allocUnsafe&&Zt.allocUnsafeSlow?Vl.exports=Qa:(Gl(Qa,ds),ds.Buffer=si);function si(t,e,r){return Zt(t,e,r)}si.prototype=Object.create(Zt.prototype);Gl(Zt,si);si.from=function(t,e,r){if(typeof t=="number")throw new TypeError("Argument must not be a number");return Zt(t,e,r)};si.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError("Argument must be a number");var n=Zt(t);return e!==void 0?typeof r=="string"?n.fill(e,r):n.fill(e):n.fill(0),n};si.allocUnsafe=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return Zt(t)};si.allocUnsafeSlow=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return Qa.SlowBuffer(t)}});var ui=R((zB,vs)=>{"use strict";w();var ps=65536,M2=4294967295;function E2(){throw new Error(`Secure random number generation is not supported by this browser.
1
+ var bsvShamir=(()=>{var Db=Object.create;var ml=Object.defineProperty;var Ub=Object.getOwnPropertyDescriptor;var Nb=Object.getOwnPropertyNames;var Lb=Object.getPrototypeOf,Fb=Object.prototype.hasOwnProperty;var jb=(t,e,r)=>()=>{if(r)throw r[0];try{return t&&(e=t(t=0)),e}catch(n){throw r=[n],n}};var R=(t,e)=>()=>{try{return e||t((e={exports:{}}).exports,e),e.exports}catch(r){throw e=0,r}};var Hb=(t,e,r,n)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of Nb(e))!Fb.call(t,i)&&i!==r&&ml(t,i,{get:()=>e[i],enumerable:!(n=Ub(e,i))||n.enumerable});return t};var bl=(t,e,r)=>(r=t!=null?Db(Lb(t)):{},Hb(e||!t||!t.__esModule?ml(r,"default",{value:t,enumerable:!0}):r,t));var El=R((CB,Ml)=>{w();var Ze=Ml.exports={},zt,Gt;function es(){throw new Error("setTimeout has not been defined")}function ts(){throw new Error("clearTimeout has not been defined")}(function(){try{typeof setTimeout=="function"?zt=setTimeout:zt=es}catch{zt=es}try{typeof clearTimeout=="function"?Gt=clearTimeout:Gt=ts}catch{Gt=ts}})();function wl(t){if(zt===setTimeout)return setTimeout(t,0);if((zt===es||!zt)&&setTimeout)return zt=setTimeout,setTimeout(t,0);try{return zt(t,0)}catch{try{return zt.call(null,t,0)}catch{return zt.call(this,t,0)}}}function Kb(t){if(Gt===clearTimeout)return clearTimeout(t);if((Gt===ts||!Gt)&&clearTimeout)return Gt=clearTimeout,clearTimeout(t);try{return Gt(t)}catch{try{return Gt.call(null,t)}catch{return Gt.call(this,t)}}}var sr=[],Ni=!1,ai,Za=-1;function Wb(){!Ni||!ai||(Ni=!1,ai.length?sr=ai.concat(sr):Za=-1,sr.length&&_l())}function _l(){if(!Ni){var t=wl(Wb);Ni=!0;for(var e=sr.length;e;){for(ai=sr,sr=[];++Za<e;)ai&&ai[Za].run();Za=-1,e=sr.length}ai=null,Ni=!1,Kb(t)}}Ze.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)e[r-1]=arguments[r];sr.push(new xl(t,e)),sr.length===1&&!Ni&&wl(_l)};function xl(t,e){this.fun=t,this.array=e}xl.prototype.run=function(){this.fun.apply(null,this.array)};Ze.title="browser";Ze.browser=!0;Ze.env={};Ze.argv=[];Ze.version="";Ze.versions={};function ur(){}Ze.on=ur;Ze.addListener=ur;Ze.once=ur;Ze.off=ur;Ze.removeListener=ur;Ze.removeAllListeners=ur;Ze.emit=ur;Ze.prependListener=ur;Ze.prependOnceListener=ur;Ze.listeners=function(t){return[]};Ze.binding=function(t){throw new Error("process.binding is not supported")};Ze.cwd=function(){return"/"};Ze.chdir=function(t){throw new Error("process.chdir is not supported")};Ze.umask=function(){return 0}});var Al=R(Ya=>{"use strict";w();Ya.byteLength=Gb;Ya.toByteArray=$b;Ya.fromByteArray=Xb;var Vt=[],wt=[],zb=typeof Uint8Array<"u"?Uint8Array:Array,rs="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(oi=0,Sl=rs.length;oi<Sl;++oi)Vt[oi]=rs[oi],wt[rs.charCodeAt(oi)]=oi;var oi,Sl;wt[45]=62;wt[95]=63;function Bl(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=t.indexOf("=");r===-1&&(r=e);var n=r===e?0:4-r%4;return[r,n]}function Gb(t){var e=Bl(t),r=e[0],n=e[1];return(r+n)*3/4-n}function Vb(t,e,r){return(e+r)*3/4-r}function $b(t){var e,r=Bl(t),n=r[0],i=r[1],a=new zb(Vb(t,n,i)),f=0,v=i>0?n-4:n,m;for(m=0;m<v;m+=4)e=wt[t.charCodeAt(m)]<<18|wt[t.charCodeAt(m+1)]<<12|wt[t.charCodeAt(m+2)]<<6|wt[t.charCodeAt(m+3)],a[f++]=e>>16&255,a[f++]=e>>8&255,a[f++]=e&255;return i===2&&(e=wt[t.charCodeAt(m)]<<2|wt[t.charCodeAt(m+1)]>>4,a[f++]=e&255),i===1&&(e=wt[t.charCodeAt(m)]<<10|wt[t.charCodeAt(m+1)]<<4|wt[t.charCodeAt(m+2)]>>2,a[f++]=e>>8&255,a[f++]=e&255),a}function Zb(t){return Vt[t>>18&63]+Vt[t>>12&63]+Vt[t>>6&63]+Vt[t&63]}function Yb(t,e,r){for(var n,i=[],a=e;a<r;a+=3)n=(t[a]<<16&16711680)+(t[a+1]<<8&65280)+(t[a+2]&255),i.push(Zb(n));return i.join("")}function Xb(t){for(var e,r=t.length,n=r%3,i=[],a=16383,f=0,v=r-n;f<v;f+=a)i.push(Yb(t,f,f+a>v?v:f+a));return n===1?(e=t[r-1],i.push(Vt[e>>2]+Vt[e<<4&63]+"==")):n===2&&(e=(t[r-2]<<8)+t[r-1],i.push(Vt[e>>10]+Vt[e>>4&63]+Vt[e<<2&63]+"=")),i.join("")}});var Rl=R(is=>{w();is.read=function(t,e,r,n,i){var a,f,v=i*8-n-1,m=(1<<v)-1,E=m>>1,A=-7,q=r?i-1:0,I=r?-1:1,C=t[e+q];for(q+=I,a=C&(1<<-A)-1,C>>=-A,A+=v;A>0;a=a*256+t[e+q],q+=I,A-=8);for(f=a&(1<<-A)-1,a>>=-A,A+=n;A>0;f=f*256+t[e+q],q+=I,A-=8);if(a===0)a=1-E;else{if(a===m)return f?NaN:(C?-1:1)*(1/0);f=f+Math.pow(2,n),a=a-E}return(C?-1:1)*f*Math.pow(2,a-n)};is.write=function(t,e,r,n,i,a){var f,v,m,E=a*8-i-1,A=(1<<E)-1,q=A>>1,I=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,C=n?0:a-1,j=n?1:-1,V=e<0||e===0&&1/e<0?1:0;for(e=Math.abs(e),isNaN(e)||e===1/0?(v=isNaN(e)?1:0,f=A):(f=Math.floor(Math.log(e)/Math.LN2),e*(m=Math.pow(2,-f))<1&&(f--,m*=2),f+q>=1?e+=I/m:e+=I*Math.pow(2,1-q),e*m>=2&&(f++,m/=2),f+q>=A?(v=0,f=A):f+q>=1?(v=(e*m-1)*Math.pow(2,i),f=f+q):(v=e*Math.pow(2,q-1)*Math.pow(2,i),f=0));i>=8;t[r+C]=v&255,C+=j,v/=256,i-=8);for(f=f<<i|v,E+=i;E>0;t[r+C]=f&255,C+=j,f/=256,E-=8);t[r+C-j]|=V*128}});var ft=R(Hi=>{"use strict";w();var ns=Al(),Fi=Rl(),ql=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;Hi.Buffer=T;Hi.SlowBuffer=i2;Hi.INSPECT_MAX_BYTES=50;var Xa=2147483647;Hi.kMaxLength=Xa;T.TYPED_ARRAY_SUPPORT=Jb();!T.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function Jb(){try{let t=new Uint8Array(1),e={foo:function(){return 42}};return Object.setPrototypeOf(e,Uint8Array.prototype),Object.setPrototypeOf(t,e),t.foo()===42}catch{return!1}}Object.defineProperty(T.prototype,"parent",{enumerable:!0,get:function(){if(T.isBuffer(this))return this.buffer}});Object.defineProperty(T.prototype,"offset",{enumerable:!0,get:function(){if(T.isBuffer(this))return this.byteOffset}});function hr(t){if(t>Xa)throw new RangeError('The value "'+t+'" is invalid for option "size"');let e=new Uint8Array(t);return Object.setPrototypeOf(e,T.prototype),e}function T(t,e,r){if(typeof t=="number"){if(typeof e=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return ss(t)}return Cl(t,e,r)}T.poolSize=8192;function Cl(t,e,r){if(typeof t=="string")return e2(t,e);if(ArrayBuffer.isView(t))return t2(t);if(t==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t);if($t(t,ArrayBuffer)||t&&$t(t.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&($t(t,SharedArrayBuffer)||t&&$t(t.buffer,SharedArrayBuffer)))return os(t,e,r);if(typeof t=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');let n=t.valueOf&&t.valueOf();if(n!=null&&n!==t)return T.from(n,e,r);let i=r2(t);if(i)return i;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof t[Symbol.toPrimitive]=="function")return T.from(t[Symbol.toPrimitive]("string"),e,r);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof t)}T.from=function(t,e,r){return Cl(t,e,r)};Object.setPrototypeOf(T.prototype,Uint8Array.prototype);Object.setPrototypeOf(T,Uint8Array);function Ol(t){if(typeof t!="number")throw new TypeError('"size" argument must be of type number');if(t<0)throw new RangeError('The value "'+t+'" is invalid for option "size"')}function Qb(t,e,r){return Ol(t),t<=0?hr(t):e!==void 0?typeof r=="string"?hr(t).fill(e,r):hr(t).fill(e):hr(t)}T.alloc=function(t,e,r){return Qb(t,e,r)};function ss(t){return Ol(t),hr(t<0?0:us(t)|0)}T.allocUnsafe=function(t){return ss(t)};T.allocUnsafeSlow=function(t){return ss(t)};function e2(t,e){if((typeof e!="string"||e==="")&&(e="utf8"),!T.isEncoding(e))throw new TypeError("Unknown encoding: "+e);let r=Pl(t,e)|0,n=hr(r),i=n.write(t,e);return i!==r&&(n=n.slice(0,i)),n}function as(t){let e=t.length<0?0:us(t.length)|0,r=hr(e);for(let n=0;n<e;n+=1)r[n]=t[n]&255;return r}function t2(t){if($t(t,Uint8Array)){let e=new Uint8Array(t);return os(e.buffer,e.byteOffset,e.byteLength)}return as(t)}function os(t,e,r){if(e<0||t.byteLength<e)throw new RangeError('"offset" is outside of buffer bounds');if(t.byteLength<e+(r||0))throw new RangeError('"length" is outside of buffer bounds');let n;return e===void 0&&r===void 0?n=new Uint8Array(t):r===void 0?n=new Uint8Array(t,e):n=new Uint8Array(t,e,r),Object.setPrototypeOf(n,T.prototype),n}function r2(t){if(T.isBuffer(t)){let e=us(t.length)|0,r=hr(e);return r.length===0||t.copy(r,0,0,e),r}if(t.length!==void 0)return typeof t.length!="number"||ls(t.length)?hr(0):as(t);if(t.type==="Buffer"&&Array.isArray(t.data))return as(t.data)}function us(t){if(t>=Xa)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+Xa.toString(16)+" bytes");return t|0}function i2(t){return+t!=t&&(t=0),T.alloc(+t)}T.isBuffer=function(e){return e!=null&&e._isBuffer===!0&&e!==T.prototype};T.compare=function(e,r){if($t(e,Uint8Array)&&(e=T.from(e,e.offset,e.byteLength)),$t(r,Uint8Array)&&(r=T.from(r,r.offset,r.byteLength)),!T.isBuffer(e)||!T.isBuffer(r))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(e===r)return 0;let n=e.length,i=r.length;for(let a=0,f=Math.min(n,i);a<f;++a)if(e[a]!==r[a]){n=e[a],i=r[a];break}return n<i?-1:i<n?1:0};T.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}};T.concat=function(e,r){if(!Array.isArray(e))throw new TypeError('"list" argument must be an Array of Buffers');if(e.length===0)return T.alloc(0);let n;if(r===void 0)for(r=0,n=0;n<e.length;++n)r+=e[n].length;let i=T.allocUnsafe(r),a=0;for(n=0;n<e.length;++n){let f=e[n];if($t(f,Uint8Array))a+f.length>i.length?(T.isBuffer(f)||(f=T.from(f)),f.copy(i,a)):Uint8Array.prototype.set.call(i,f,a);else if(T.isBuffer(f))f.copy(i,a);else throw new TypeError('"list" argument must be an Array of Buffers');a+=f.length}return i};function Pl(t,e){if(T.isBuffer(t))return t.length;if(ArrayBuffer.isView(t)||$t(t,ArrayBuffer))return t.byteLength;if(typeof t!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof t);let r=t.length,n=arguments.length>2&&arguments[2]===!0;if(!n&&r===0)return 0;let i=!1;for(;;)switch(e){case"ascii":case"latin1":case"binary":return r;case"utf8":case"utf-8":return fs(t).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return r*2;case"hex":return r>>>1;case"base64":return Wl(t).length;default:if(i)return n?-1:fs(t).length;e=(""+e).toLowerCase(),i=!0}}T.byteLength=Pl;function n2(t,e,r){let n=!1;if((e===void 0||e<0)&&(e=0),e>this.length||((r===void 0||r>this.length)&&(r=this.length),r<=0)||(r>>>=0,e>>>=0,r<=e))return"";for(t||(t="utf8");;)switch(t){case"hex":return p2(this,e,r);case"utf8":case"utf-8":return Ul(this,e,r);case"ascii":return c2(this,e,r);case"latin1":case"binary":return d2(this,e,r);case"base64":return h2(this,e,r);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return v2(this,e,r);default:if(n)throw new TypeError("Unknown encoding: "+t);t=(t+"").toLowerCase(),n=!0}}T.prototype._isBuffer=!0;function fi(t,e,r){let n=t[e];t[e]=t[r],t[r]=n}T.prototype.swap16=function(){let e=this.length;if(e%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let r=0;r<e;r+=2)fi(this,r,r+1);return this};T.prototype.swap32=function(){let e=this.length;if(e%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let r=0;r<e;r+=4)fi(this,r,r+3),fi(this,r+1,r+2);return this};T.prototype.swap64=function(){let e=this.length;if(e%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let r=0;r<e;r+=8)fi(this,r,r+7),fi(this,r+1,r+6),fi(this,r+2,r+5),fi(this,r+3,r+4);return this};T.prototype.toString=function(){let e=this.length;return e===0?"":arguments.length===0?Ul(this,0,e):n2.apply(this,arguments)};T.prototype.toLocaleString=T.prototype.toString;T.prototype.equals=function(e){if(!T.isBuffer(e))throw new TypeError("Argument must be a Buffer");return this===e?!0:T.compare(this,e)===0};T.prototype.inspect=function(){let e="",r=Hi.INSPECT_MAX_BYTES;return e=this.toString("hex",0,r).replace(/(.{2})/g,"$1 ").trim(),this.length>r&&(e+=" ... "),"<Buffer "+e+">"};ql&&(T.prototype[ql]=T.prototype.inspect);T.prototype.compare=function(e,r,n,i,a){if($t(e,Uint8Array)&&(e=T.from(e,e.offset,e.byteLength)),!T.isBuffer(e))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof e);if(r===void 0&&(r=0),n===void 0&&(n=e?e.length:0),i===void 0&&(i=0),a===void 0&&(a=this.length),r<0||n>e.length||i<0||a>this.length)throw new RangeError("out of range index");if(i>=a&&r>=n)return 0;if(i>=a)return-1;if(r>=n)return 1;if(r>>>=0,n>>>=0,i>>>=0,a>>>=0,this===e)return 0;let f=a-i,v=n-r,m=Math.min(f,v),E=this.slice(i,a),A=e.slice(r,n);for(let q=0;q<m;++q)if(E[q]!==A[q]){f=E[q],v=A[q];break}return f<v?-1:v<f?1:0};function Dl(t,e,r,n,i){if(t.length===0)return-1;if(typeof r=="string"?(n=r,r=0):r>2147483647?r=2147483647:r<-2147483648&&(r=-2147483648),r=+r,ls(r)&&(r=i?0:t.length-1),r<0&&(r=t.length+r),r>=t.length){if(i)return-1;r=t.length-1}else if(r<0)if(i)r=0;else return-1;if(typeof e=="string"&&(e=T.from(e,n)),T.isBuffer(e))return e.length===0?-1:Il(t,e,r,n,i);if(typeof e=="number")return e=e&255,typeof Uint8Array.prototype.indexOf=="function"?i?Uint8Array.prototype.indexOf.call(t,e,r):Uint8Array.prototype.lastIndexOf.call(t,e,r):Il(t,[e],r,n,i);throw new TypeError("val must be string, number or Buffer")}function Il(t,e,r,n,i){let a=1,f=t.length,v=e.length;if(n!==void 0&&(n=String(n).toLowerCase(),n==="ucs2"||n==="ucs-2"||n==="utf16le"||n==="utf-16le")){if(t.length<2||e.length<2)return-1;a=2,f/=2,v/=2,r/=2}function m(A,q){return a===1?A[q]:A.readUInt16BE(q*a)}let E;if(i){let A=-1;for(E=r;E<f;E++)if(m(t,E)===m(e,A===-1?0:E-A)){if(A===-1&&(A=E),E-A+1===v)return A*a}else A!==-1&&(E-=E-A),A=-1}else for(r+v>f&&(r=f-v),E=r;E>=0;E--){let A=!0;for(let q=0;q<v;q++)if(m(t,E+q)!==m(e,q)){A=!1;break}if(A)return E}return-1}T.prototype.includes=function(e,r,n){return this.indexOf(e,r,n)!==-1};T.prototype.indexOf=function(e,r,n){return Dl(this,e,r,n,!0)};T.prototype.lastIndexOf=function(e,r,n){return Dl(this,e,r,n,!1)};function a2(t,e,r,n){r=Number(r)||0;let i=t.length-r;n?(n=Number(n),n>i&&(n=i)):n=i;let a=e.length;n>a/2&&(n=a/2);let f;for(f=0;f<n;++f){let v=parseInt(e.substr(f*2,2),16);if(ls(v))return f;t[r+f]=v}return f}function o2(t,e,r,n){return Ja(fs(e,t.length-r),t,r,n)}function f2(t,e,r,n){return Ja(b2(e),t,r,n)}function s2(t,e,r,n){return Ja(Wl(e),t,r,n)}function u2(t,e,r,n){return Ja(w2(e,t.length-r),t,r,n)}T.prototype.write=function(e,r,n,i){if(r===void 0)i="utf8",n=this.length,r=0;else if(n===void 0&&typeof r=="string")i=r,n=this.length,r=0;else if(isFinite(r))r=r>>>0,isFinite(n)?(n=n>>>0,i===void 0&&(i="utf8")):(i=n,n=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");let a=this.length-r;if((n===void 0||n>a)&&(n=a),e.length>0&&(n<0||r<0)||r>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");let f=!1;for(;;)switch(i){case"hex":return a2(this,e,r,n);case"utf8":case"utf-8":return o2(this,e,r,n);case"ascii":case"latin1":case"binary":return f2(this,e,r,n);case"base64":return s2(this,e,r,n);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return u2(this,e,r,n);default:if(f)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),f=!0}};T.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function h2(t,e,r){return e===0&&r===t.length?ns.fromByteArray(t):ns.fromByteArray(t.slice(e,r))}function Ul(t,e,r){r=Math.min(t.length,r);let n=[],i=e;for(;i<r;){let a=t[i],f=null,v=a>239?4:a>223?3:a>191?2:1;if(i+v<=r){let m,E,A,q;switch(v){case 1:a<128&&(f=a);break;case 2:m=t[i+1],(m&192)===128&&(q=(a&31)<<6|m&63,q>127&&(f=q));break;case 3:m=t[i+1],E=t[i+2],(m&192)===128&&(E&192)===128&&(q=(a&15)<<12|(m&63)<<6|E&63,q>2047&&(q<55296||q>57343)&&(f=q));break;case 4:m=t[i+1],E=t[i+2],A=t[i+3],(m&192)===128&&(E&192)===128&&(A&192)===128&&(q=(a&15)<<18|(m&63)<<12|(E&63)<<6|A&63,q>65535&&q<1114112&&(f=q))}}f===null?(f=65533,v=1):f>65535&&(f-=65536,n.push(f>>>10&1023|55296),f=56320|f&1023),n.push(f),i+=v}return l2(n)}var kl=4096;function l2(t){let e=t.length;if(e<=kl)return String.fromCharCode.apply(String,t);let r="",n=0;for(;n<e;)r+=String.fromCharCode.apply(String,t.slice(n,n+=kl));return r}function c2(t,e,r){let n="";r=Math.min(t.length,r);for(let i=e;i<r;++i)n+=String.fromCharCode(t[i]&127);return n}function d2(t,e,r){let n="";r=Math.min(t.length,r);for(let i=e;i<r;++i)n+=String.fromCharCode(t[i]);return n}function p2(t,e,r){let n=t.length;(!e||e<0)&&(e=0),(!r||r<0||r>n)&&(r=n);let i="";for(let a=e;a<r;++a)i+=_2[t[a]];return i}function v2(t,e,r){let n=t.slice(e,r),i="";for(let a=0;a<n.length-1;a+=2)i+=String.fromCharCode(n[a]+n[a+1]*256);return i}T.prototype.slice=function(e,r){let n=this.length;e=~~e,r=r===void 0?n:~~r,e<0?(e+=n,e<0&&(e=0)):e>n&&(e=n),r<0?(r+=n,r<0&&(r=0)):r>n&&(r=n),r<e&&(r=e);let i=this.subarray(e,r);return Object.setPrototypeOf(i,T.prototype),i};function rt(t,e,r){if(t%1!==0||t<0)throw new RangeError("offset is not uint");if(t+e>r)throw new RangeError("Trying to access beyond buffer length")}T.prototype.readUintLE=T.prototype.readUIntLE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=this[e],a=1,f=0;for(;++f<r&&(a*=256);)i+=this[e+f]*a;return i};T.prototype.readUintBE=T.prototype.readUIntBE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=this[e+--r],a=1;for(;r>0&&(a*=256);)i+=this[e+--r]*a;return i};T.prototype.readUint8=T.prototype.readUInt8=function(e,r){return e=e>>>0,r||rt(e,1,this.length),this[e]};T.prototype.readUint16LE=T.prototype.readUInt16LE=function(e,r){return e=e>>>0,r||rt(e,2,this.length),this[e]|this[e+1]<<8};T.prototype.readUint16BE=T.prototype.readUInt16BE=function(e,r){return e=e>>>0,r||rt(e,2,this.length),this[e]<<8|this[e+1]};T.prototype.readUint32LE=T.prototype.readUInt32LE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+this[e+3]*16777216};T.prototype.readUint32BE=T.prototype.readUInt32BE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),this[e]*16777216+(this[e+1]<<16|this[e+2]<<8|this[e+3])};T.prototype.readBigUInt64LE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=r+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24,a=this[++e]+this[++e]*2**8+this[++e]*2**16+n*2**24;return BigInt(i)+(BigInt(a)<<BigInt(32))});T.prototype.readBigUInt64BE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=r*2**24+this[++e]*2**16+this[++e]*2**8+this[++e],a=this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n;return(BigInt(i)<<BigInt(32))+BigInt(a)});T.prototype.readIntLE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=this[e],a=1,f=0;for(;++f<r&&(a*=256);)i+=this[e+f]*a;return a*=128,i>=a&&(i-=Math.pow(2,8*r)),i};T.prototype.readIntBE=function(e,r,n){e=e>>>0,r=r>>>0,n||rt(e,r,this.length);let i=r,a=1,f=this[e+--i];for(;i>0&&(a*=256);)f+=this[e+--i]*a;return a*=128,f>=a&&(f-=Math.pow(2,8*r)),f};T.prototype.readInt8=function(e,r){return e=e>>>0,r||rt(e,1,this.length),this[e]&128?(255-this[e]+1)*-1:this[e]};T.prototype.readInt16LE=function(e,r){e=e>>>0,r||rt(e,2,this.length);let n=this[e]|this[e+1]<<8;return n&32768?n|4294901760:n};T.prototype.readInt16BE=function(e,r){e=e>>>0,r||rt(e,2,this.length);let n=this[e+1]|this[e]<<8;return n&32768?n|4294901760:n};T.prototype.readInt32LE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24};T.prototype.readInt32BE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]};T.prototype.readBigInt64LE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=this[e+4]+this[e+5]*2**8+this[e+6]*2**16+(n<<24);return(BigInt(i)<<BigInt(32))+BigInt(r+this[++e]*2**8+this[++e]*2**16+this[++e]*2**24)});T.prototype.readBigInt64BE=Ir(function(e){e=e>>>0,ji(e,"offset");let r=this[e],n=this[e+7];(r===void 0||n===void 0)&&$n(e,this.length-8);let i=(r<<24)+this[++e]*2**16+this[++e]*2**8+this[++e];return(BigInt(i)<<BigInt(32))+BigInt(this[++e]*2**24+this[++e]*2**16+this[++e]*2**8+n)});T.prototype.readFloatLE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),Fi.read(this,e,!0,23,4)};T.prototype.readFloatBE=function(e,r){return e=e>>>0,r||rt(e,4,this.length),Fi.read(this,e,!1,23,4)};T.prototype.readDoubleLE=function(e,r){return e=e>>>0,r||rt(e,8,this.length),Fi.read(this,e,!0,52,8)};T.prototype.readDoubleBE=function(e,r){return e=e>>>0,r||rt(e,8,this.length),Fi.read(this,e,!1,52,8)};function vt(t,e,r,n,i,a){if(!T.isBuffer(t))throw new TypeError('"buffer" argument must be a Buffer instance');if(e>i||e<a)throw new RangeError('"value" argument is out of bounds');if(r+n>t.length)throw new RangeError("Index out of range")}T.prototype.writeUintLE=T.prototype.writeUIntLE=function(e,r,n,i){if(e=+e,r=r>>>0,n=n>>>0,!i){let v=Math.pow(2,8*n)-1;vt(this,e,r,n,v,0)}let a=1,f=0;for(this[r]=e&255;++f<n&&(a*=256);)this[r+f]=e/a&255;return r+n};T.prototype.writeUintBE=T.prototype.writeUIntBE=function(e,r,n,i){if(e=+e,r=r>>>0,n=n>>>0,!i){let v=Math.pow(2,8*n)-1;vt(this,e,r,n,v,0)}let a=n-1,f=1;for(this[r+a]=e&255;--a>=0&&(f*=256);)this[r+a]=e/f&255;return r+n};T.prototype.writeUint8=T.prototype.writeUInt8=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,1,255,0),this[r]=e&255,r+1};T.prototype.writeUint16LE=T.prototype.writeUInt16LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,65535,0),this[r]=e&255,this[r+1]=e>>>8,r+2};T.prototype.writeUint16BE=T.prototype.writeUInt16BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,65535,0),this[r]=e>>>8,this[r+1]=e&255,r+2};T.prototype.writeUint32LE=T.prototype.writeUInt32LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,4294967295,0),this[r+3]=e>>>24,this[r+2]=e>>>16,this[r+1]=e>>>8,this[r]=e&255,r+4};T.prototype.writeUint32BE=T.prototype.writeUInt32BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,4294967295,0),this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255,r+4};function Nl(t,e,r,n,i){Kl(e,n,i,t,r,7);let a=Number(e&BigInt(4294967295));t[r++]=a,a=a>>8,t[r++]=a,a=a>>8,t[r++]=a,a=a>>8,t[r++]=a;let f=Number(e>>BigInt(32)&BigInt(4294967295));return t[r++]=f,f=f>>8,t[r++]=f,f=f>>8,t[r++]=f,f=f>>8,t[r++]=f,r}function Ll(t,e,r,n,i){Kl(e,n,i,t,r,7);let a=Number(e&BigInt(4294967295));t[r+7]=a,a=a>>8,t[r+6]=a,a=a>>8,t[r+5]=a,a=a>>8,t[r+4]=a;let f=Number(e>>BigInt(32)&BigInt(4294967295));return t[r+3]=f,f=f>>8,t[r+2]=f,f=f>>8,t[r+1]=f,f=f>>8,t[r]=f,r+8}T.prototype.writeBigUInt64LE=Ir(function(e,r=0){return Nl(this,e,r,BigInt(0),BigInt("0xffffffffffffffff"))});T.prototype.writeBigUInt64BE=Ir(function(e,r=0){return Ll(this,e,r,BigInt(0),BigInt("0xffffffffffffffff"))});T.prototype.writeIntLE=function(e,r,n,i){if(e=+e,r=r>>>0,!i){let m=Math.pow(2,8*n-1);vt(this,e,r,n,m-1,-m)}let a=0,f=1,v=0;for(this[r]=e&255;++a<n&&(f*=256);)e<0&&v===0&&this[r+a-1]!==0&&(v=1),this[r+a]=(e/f>>0)-v&255;return r+n};T.prototype.writeIntBE=function(e,r,n,i){if(e=+e,r=r>>>0,!i){let m=Math.pow(2,8*n-1);vt(this,e,r,n,m-1,-m)}let a=n-1,f=1,v=0;for(this[r+a]=e&255;--a>=0&&(f*=256);)e<0&&v===0&&this[r+a+1]!==0&&(v=1),this[r+a]=(e/f>>0)-v&255;return r+n};T.prototype.writeInt8=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,1,127,-128),e<0&&(e=255+e+1),this[r]=e&255,r+1};T.prototype.writeInt16LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,32767,-32768),this[r]=e&255,this[r+1]=e>>>8,r+2};T.prototype.writeInt16BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,2,32767,-32768),this[r]=e>>>8,this[r+1]=e&255,r+2};T.prototype.writeInt32LE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,2147483647,-2147483648),this[r]=e&255,this[r+1]=e>>>8,this[r+2]=e>>>16,this[r+3]=e>>>24,r+4};T.prototype.writeInt32BE=function(e,r,n){return e=+e,r=r>>>0,n||vt(this,e,r,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),this[r]=e>>>24,this[r+1]=e>>>16,this[r+2]=e>>>8,this[r+3]=e&255,r+4};T.prototype.writeBigInt64LE=Ir(function(e,r=0){return Nl(this,e,r,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});T.prototype.writeBigInt64BE=Ir(function(e,r=0){return Ll(this,e,r,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function Fl(t,e,r,n,i,a){if(r+n>t.length)throw new RangeError("Index out of range");if(r<0)throw new RangeError("Index out of range")}function jl(t,e,r,n,i){return e=+e,r=r>>>0,i||Fl(t,e,r,4,34028234663852886e22,-34028234663852886e22),Fi.write(t,e,r,n,23,4),r+4}T.prototype.writeFloatLE=function(e,r,n){return jl(this,e,r,!0,n)};T.prototype.writeFloatBE=function(e,r,n){return jl(this,e,r,!1,n)};function Hl(t,e,r,n,i){return e=+e,r=r>>>0,i||Fl(t,e,r,8,17976931348623157e292,-17976931348623157e292),Fi.write(t,e,r,n,52,8),r+8}T.prototype.writeDoubleLE=function(e,r,n){return Hl(this,e,r,!0,n)};T.prototype.writeDoubleBE=function(e,r,n){return Hl(this,e,r,!1,n)};T.prototype.copy=function(e,r,n,i){if(!T.isBuffer(e))throw new TypeError("argument should be a Buffer");if(n||(n=0),!i&&i!==0&&(i=this.length),r>=e.length&&(r=e.length),r||(r=0),i>0&&i<n&&(i=n),i===n||e.length===0||this.length===0)return 0;if(r<0)throw new RangeError("targetStart out of bounds");if(n<0||n>=this.length)throw new RangeError("Index out of range");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-r<i-n&&(i=e.length-r+n);let a=i-n;return this===e&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(r,n,i):Uint8Array.prototype.set.call(e,this.subarray(n,i),r),a};T.prototype.fill=function(e,r,n,i){if(typeof e=="string"){if(typeof r=="string"?(i=r,r=0,n=this.length):typeof n=="string"&&(i=n,n=this.length),i!==void 0&&typeof i!="string")throw new TypeError("encoding must be a string");if(typeof i=="string"&&!T.isEncoding(i))throw new TypeError("Unknown encoding: "+i);if(e.length===1){let f=e.charCodeAt(0);(i==="utf8"&&f<128||i==="latin1")&&(e=f)}}else typeof e=="number"?e=e&255:typeof e=="boolean"&&(e=Number(e));if(r<0||this.length<r||this.length<n)throw new RangeError("Out of range index");if(n<=r)return this;r=r>>>0,n=n===void 0?this.length:n>>>0,e||(e=0);let a;if(typeof e=="number")for(a=r;a<n;++a)this[a]=e;else{let f=T.isBuffer(e)?e:T.from(e,i),v=f.length;if(v===0)throw new TypeError('The value "'+e+'" is invalid for argument "value"');for(a=0;a<n-r;++a)this[a+r]=f[a%v]}return this};var Li={};function hs(t,e,r){Li[t]=class extends r{constructor(){super(),Object.defineProperty(this,"message",{value:e.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${t}]`,this.stack,delete this.name}get code(){return t}set code(i){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:i,writable:!0})}toString(){return`${this.name} [${t}]: ${this.message}`}}}hs("ERR_BUFFER_OUT_OF_BOUNDS",function(t){return t?`${t} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError);hs("ERR_INVALID_ARG_TYPE",function(t,e){return`The "${t}" argument must be of type number. Received type ${typeof e}`},TypeError);hs("ERR_OUT_OF_RANGE",function(t,e,r){let n=`The value of "${t}" is out of range.`,i=r;return Number.isInteger(r)&&Math.abs(r)>2**32?i=Tl(String(r)):typeof r=="bigint"&&(i=String(r),(r>BigInt(2)**BigInt(32)||r<-(BigInt(2)**BigInt(32)))&&(i=Tl(i)),i+="n"),n+=` It must be ${e}. Received ${i}`,n},RangeError);function Tl(t){let e="",r=t.length,n=t[0]==="-"?1:0;for(;r>=n+4;r-=3)e=`_${t.slice(r-3,r)}${e}`;return`${t.slice(0,r)}${e}`}function y2(t,e,r){ji(e,"offset"),(t[e]===void 0||t[e+r]===void 0)&&$n(e,t.length-(r+1))}function Kl(t,e,r,n,i,a){if(t>r||t<e){let f=typeof e=="bigint"?"n":"",v;throw a>3?e===0||e===BigInt(0)?v=`>= 0${f} and < 2${f} ** ${(a+1)*8}${f}`:v=`>= -(2${f} ** ${(a+1)*8-1}${f}) and < 2 ** ${(a+1)*8-1}${f}`:v=`>= ${e}${f} and <= ${r}${f}`,new Li.ERR_OUT_OF_RANGE("value",v,t)}y2(n,i,a)}function ji(t,e){if(typeof t!="number")throw new Li.ERR_INVALID_ARG_TYPE(e,"number",t)}function $n(t,e,r){throw Math.floor(t)!==t?(ji(t,r),new Li.ERR_OUT_OF_RANGE(r||"offset","an integer",t)):e<0?new Li.ERR_BUFFER_OUT_OF_BOUNDS:new Li.ERR_OUT_OF_RANGE(r||"offset",`>= ${r?1:0} and <= ${e}`,t)}var g2=/[^+/0-9A-Za-z-_]/g;function m2(t){if(t=t.split("=")[0],t=t.trim().replace(g2,""),t.length<2)return"";for(;t.length%4!==0;)t=t+"=";return t}function fs(t,e){e=e||1/0;let r,n=t.length,i=null,a=[];for(let f=0;f<n;++f){if(r=t.charCodeAt(f),r>55295&&r<57344){if(!i){if(r>56319){(e-=3)>-1&&a.push(239,191,189);continue}else if(f+1===n){(e-=3)>-1&&a.push(239,191,189);continue}i=r;continue}if(r<56320){(e-=3)>-1&&a.push(239,191,189),i=r;continue}r=(i-55296<<10|r-56320)+65536}else i&&(e-=3)>-1&&a.push(239,191,189);if(i=null,r<128){if((e-=1)<0)break;a.push(r)}else if(r<2048){if((e-=2)<0)break;a.push(r>>6|192,r&63|128)}else if(r<65536){if((e-=3)<0)break;a.push(r>>12|224,r>>6&63|128,r&63|128)}else if(r<1114112){if((e-=4)<0)break;a.push(r>>18|240,r>>12&63|128,r>>6&63|128,r&63|128)}else throw new Error("Invalid code point")}return a}function b2(t){let e=[];for(let r=0;r<t.length;++r)e.push(t.charCodeAt(r)&255);return e}function w2(t,e){let r,n,i,a=[];for(let f=0;f<t.length&&!((e-=2)<0);++f)r=t.charCodeAt(f),n=r>>8,i=r%256,a.push(i),a.push(n);return a}function Wl(t){return ns.toByteArray(m2(t))}function Ja(t,e,r,n){let i;for(i=0;i<n&&!(i+r>=e.length||i>=t.length);++i)e[i+r]=t[i];return i}function $t(t,e){return t instanceof e||t!=null&&t.constructor!=null&&t.constructor.name!=null&&t.constructor.name===e.name}function ls(t){return t!==t}var _2=(function(){let t="0123456789abcdef",e=new Array(256);for(let r=0;r<16;++r){let n=r*16;for(let i=0;i<16;++i)e[n+i]=t[r]+t[i]}return e})();function Ir(t){return typeof BigInt>"u"?x2:t}function x2(){throw new Error("BigInt not supported")}});var S,B,w=jb(()=>{S=bl(El()),B=bl(ft())});var lr=R((zl,cs)=>{w();(function(t,e){"use strict";function r(M,h){if(!M)throw new Error(h||"Assertion failed")}function n(M,h){M.super_=h;var y=function(){};y.prototype=h.prototype,M.prototype=new y,M.prototype.constructor=M}function i(M,h,y){if(i.isBN(M))return M;this.negative=0,this.words=null,this.length=0,this.red=null,M!==null&&((h==="le"||h==="be")&&(y=h,h=10),this._init(M||0,h||10,y||"be"))}typeof t=="object"?t.exports=i:e.BN=i,i.BN=i,i.wordSize=26;var a;try{typeof window<"u"&&typeof window.Buffer<"u"?a=window.Buffer:a=ft().Buffer}catch{}i.isBN=function(h){return h instanceof i?!0:h!==null&&typeof h=="object"&&h.constructor.wordSize===i.wordSize&&Array.isArray(h.words)},i.max=function(h,y){return h.cmp(y)>0?h:y},i.min=function(h,y){return h.cmp(y)<0?h:y},i.prototype._init=function(h,y,l){if(typeof h=="number")return this._initNumber(h,y,l);if(typeof h=="object")return this._initArray(h,y,l);y==="hex"&&(y=16),r(y===(y|0)&&y>=2&&y<=36),h=h.toString().replace(/\s+/g,"");var o=0;h[0]==="-"&&(o++,this.negative=1),o<h.length&&(y===16?this._parseHex(h,o,l):(this._parseBase(h,y,o),l==="le"&&this._initArray(this.toArray(),y,l)))},i.prototype._initNumber=function(h,y,l){h<0&&(this.negative=1,h=-h),h<67108864?(this.words=[h&67108863],this.length=1):h<4503599627370496?(this.words=[h&67108863,h/67108864&67108863],this.length=2):(r(h<9007199254740992),this.words=[h&67108863,h/67108864&67108863,1],this.length=3),l==="le"&&this._initArray(this.toArray(),y,l)},i.prototype._initArray=function(h,y,l){if(r(typeof h.length=="number"),h.length<=0)return this.words=[0],this.length=1,this;this.length=Math.ceil(h.length/3),this.words=new Array(this.length);for(var o=0;o<this.length;o++)this.words[o]=0;var s,d,g=0;if(l==="be")for(o=h.length-1,s=0;o>=0;o-=3)d=h[o]|h[o-1]<<8|h[o-2]<<16,this.words[s]|=d<<g&67108863,this.words[s+1]=d>>>26-g&67108863,g+=24,g>=26&&(g-=26,s++);else if(l==="le")for(o=0,s=0;o<h.length;o+=3)d=h[o]|h[o+1]<<8|h[o+2]<<16,this.words[s]|=d<<g&67108863,this.words[s+1]=d>>>26-g&67108863,g+=24,g>=26&&(g-=26,s++);return this.strip()};function f(M,h){var y=M.charCodeAt(h);return y>=65&&y<=70?y-55:y>=97&&y<=102?y-87:y-48&15}function v(M,h,y){var l=f(M,y);return y-1>=h&&(l|=f(M,y-1)<<4),l}i.prototype._parseHex=function(h,y,l){this.length=Math.ceil((h.length-y)/6),this.words=new Array(this.length);for(var o=0;o<this.length;o++)this.words[o]=0;var s=0,d=0,g;if(l==="be")for(o=h.length-1;o>=y;o-=2)g=v(h,y,o)<<s,this.words[d]|=g&67108863,s>=18?(s-=18,d+=1,this.words[d]|=g>>>26):s+=8;else{var p=h.length-y;for(o=p%2===0?y+1:y;o<h.length;o+=2)g=v(h,y,o)<<s,this.words[d]|=g&67108863,s>=18?(s-=18,d+=1,this.words[d]|=g>>>26):s+=8}this.strip()};function m(M,h,y,l){for(var o=0,s=Math.min(M.length,y),d=h;d<s;d++){var g=M.charCodeAt(d)-48;o*=l,g>=49?o+=g-49+10:g>=17?o+=g-17+10:o+=g}return o}i.prototype._parseBase=function(h,y,l){this.words=[0],this.length=1;for(var o=0,s=1;s<=67108863;s*=y)o++;o--,s=s/y|0;for(var d=h.length-l,g=d%o,p=Math.min(d,d-g)+l,u=0,b=l;b<p;b+=o)u=m(h,b,b+o,y),this.imuln(s),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u);if(g!==0){var _=1;for(u=m(h,b,h.length,y),b=0;b<g;b++)_*=y;this.imuln(_),this.words[0]+u<67108864?this.words[0]+=u:this._iaddn(u)}this.strip()},i.prototype.copy=function(h){h.words=new Array(this.length);for(var y=0;y<this.length;y++)h.words[y]=this.words[y];h.length=this.length,h.negative=this.negative,h.red=this.red},i.prototype.clone=function(){var h=new i(null);return this.copy(h),h},i.prototype._expand=function(h){for(;this.length<h;)this.words[this.length++]=0;return this},i.prototype.strip=function(){for(;this.length>1&&this.words[this.length-1]===0;)this.length--;return this._normSign()},i.prototype._normSign=function(){return this.length===1&&this.words[0]===0&&(this.negative=0),this},i.prototype.inspect=function(){return(this.red?"<BN-R: ":"<BN: ")+this.toString(16)+">"};var E=["","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"],A=[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],q=[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];i.prototype.toString=function(h,y){h=h||10,y=y|0||1;var l;if(h===16||h==="hex"){l="";for(var o=0,s=0,d=0;d<this.length;d++){var g=this.words[d],p=((g<<o|s)&16777215).toString(16);s=g>>>24-o&16777215,o+=2,o>=26&&(o-=26,d--),s!==0||d!==this.length-1?l=E[6-p.length]+p+l:l=p+l}for(s!==0&&(l=s.toString(16)+l);l.length%y!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}if(h===(h|0)&&h>=2&&h<=36){var u=A[h],b=q[h];l="";var _=this.clone();for(_.negative=0;!_.isZero();){var c=_.modn(b).toString(h);_=_.idivn(b),_.isZero()?l=c+l:l=E[u-c.length]+c+l}for(this.isZero()&&(l="0"+l);l.length%y!==0;)l="0"+l;return this.negative!==0&&(l="-"+l),l}r(!1,"Base should be between 2 and 36")},i.prototype.toNumber=function(){var h=this.words[0];return this.length===2?h+=this.words[1]*67108864:this.length===3&&this.words[2]===1?h+=4503599627370496+this.words[1]*67108864:this.length>2&&r(!1,"Number can only safely store up to 53 bits"),this.negative!==0?-h:h},i.prototype.toJSON=function(){return this.toString(16)},i.prototype.toBuffer=function(h,y){return r(typeof a<"u"),this.toArrayLike(a,h,y)},i.prototype.toArray=function(h,y){return this.toArrayLike(Array,h,y)},i.prototype.toArrayLike=function(h,y,l){var o=this.byteLength(),s=l||Math.max(1,o);r(o<=s,"byte array longer than desired length"),r(s>0,"Requested array length <= 0"),this.strip();var d=y==="le",g=new h(s),p,u,b=this.clone();if(d){for(u=0;!b.isZero();u++)p=b.andln(255),b.iushrn(8),g[u]=p;for(;u<s;u++)g[u]=0}else{for(u=0;u<s-o;u++)g[u]=0;for(u=0;!b.isZero();u++)p=b.andln(255),b.iushrn(8),g[s-u-1]=p}return g},Math.clz32?i.prototype._countBits=function(h){return 32-Math.clz32(h)}:i.prototype._countBits=function(h){var y=h,l=0;return y>=4096&&(l+=13,y>>>=13),y>=64&&(l+=7,y>>>=7),y>=8&&(l+=4,y>>>=4),y>=2&&(l+=2,y>>>=2),l+y},i.prototype._zeroBits=function(h){if(h===0)return 26;var y=h,l=0;return(y&8191)===0&&(l+=13,y>>>=13),(y&127)===0&&(l+=7,y>>>=7),(y&15)===0&&(l+=4,y>>>=4),(y&3)===0&&(l+=2,y>>>=2),(y&1)===0&&l++,l},i.prototype.bitLength=function(){var h=this.words[this.length-1],y=this._countBits(h);return(this.length-1)*26+y};function I(M){for(var h=new Array(M.bitLength()),y=0;y<h.length;y++){var l=y/26|0,o=y%26;h[y]=(M.words[l]&1<<o)>>>o}return h}i.prototype.zeroBits=function(){if(this.isZero())return 0;for(var h=0,y=0;y<this.length;y++){var l=this._zeroBits(this.words[y]);if(h+=l,l!==26)break}return h},i.prototype.byteLength=function(){return Math.ceil(this.bitLength()/8)},i.prototype.toTwos=function(h){return this.negative!==0?this.abs().inotn(h).iaddn(1):this.clone()},i.prototype.fromTwos=function(h){return this.testn(h-1)?this.notn(h).iaddn(1).ineg():this.clone()},i.prototype.isNeg=function(){return this.negative!==0},i.prototype.neg=function(){return this.clone().ineg()},i.prototype.ineg=function(){return this.isZero()||(this.negative^=1),this},i.prototype.iuor=function(h){for(;this.length<h.length;)this.words[this.length++]=0;for(var y=0;y<h.length;y++)this.words[y]=this.words[y]|h.words[y];return this.strip()},i.prototype.ior=function(h){return r((this.negative|h.negative)===0),this.iuor(h)},i.prototype.or=function(h){return this.length>h.length?this.clone().ior(h):h.clone().ior(this)},i.prototype.uor=function(h){return this.length>h.length?this.clone().iuor(h):h.clone().iuor(this)},i.prototype.iuand=function(h){var y;this.length>h.length?y=h:y=this;for(var l=0;l<y.length;l++)this.words[l]=this.words[l]&h.words[l];return this.length=y.length,this.strip()},i.prototype.iand=function(h){return r((this.negative|h.negative)===0),this.iuand(h)},i.prototype.and=function(h){return this.length>h.length?this.clone().iand(h):h.clone().iand(this)},i.prototype.uand=function(h){return this.length>h.length?this.clone().iuand(h):h.clone().iuand(this)},i.prototype.iuxor=function(h){var y,l;this.length>h.length?(y=this,l=h):(y=h,l=this);for(var o=0;o<l.length;o++)this.words[o]=y.words[o]^l.words[o];if(this!==y)for(;o<y.length;o++)this.words[o]=y.words[o];return this.length=y.length,this.strip()},i.prototype.ixor=function(h){return r((this.negative|h.negative)===0),this.iuxor(h)},i.prototype.xor=function(h){return this.length>h.length?this.clone().ixor(h):h.clone().ixor(this)},i.prototype.uxor=function(h){return this.length>h.length?this.clone().iuxor(h):h.clone().iuxor(this)},i.prototype.inotn=function(h){r(typeof h=="number"&&h>=0);var y=Math.ceil(h/26)|0,l=h%26;this._expand(y),l>0&&y--;for(var o=0;o<y;o++)this.words[o]=~this.words[o]&67108863;for(l>0&&(this.words[o]=~this.words[o]&67108863>>26-l,o++);o<this.length;o++)this.words[o]=0;return this.strip()},i.prototype.notn=function(h){return this.clone().inotn(h)},i.prototype.setn=function(h,y){r(typeof h=="number"&&h>=0);var l=h/26|0,o=h%26;return this._expand(l+1),y?this.words[l]=this.words[l]|1<<o:this.words[l]=this.words[l]&~(1<<o),this.strip()},i.prototype.iadd=function(h){var y;if(this.negative!==0&&h.negative===0)return this.negative=0,y=this.isub(h),this.negative^=1,this._normSign();if(this.negative===0&&h.negative!==0)return h.negative=0,y=this.isub(h),h.negative=1,y._normSign();var l,o;this.length>h.length?(l=this,o=h):(l=h,o=this);for(var s=0,d=0;d<o.length;d++)y=(l.words[d]|0)+(o.words[d]|0)+s,this.words[d]=y&67108863,s=y>>>26;for(;s!==0&&d<l.length;d++)y=(l.words[d]|0)+s,this.words[d]=y&67108863,s=y>>>26;if(this.length=l.length,s!==0)this.words[this.length]=s,this.length++;else if(l!==this)for(;d<l.length;d++)this.words[d]=l.words[d];return this},i.prototype.add=function(h){var y;return h.negative!==0&&this.negative===0?(h.negative=0,y=this.sub(h),h.negative^=1,y):h.negative===0&&this.negative!==0?(this.negative=0,y=h.sub(this),this.negative=1,y):this.length>h.length?this.clone().iadd(h):h.clone().iadd(this)},i.prototype.isub=function(h){if(h.negative!==0){h.negative=0;var y=this.iadd(h);return h.negative=1,y._normSign()}else if(this.negative!==0)return this.negative=0,this.iadd(h),this.negative=1,this._normSign();var l=this.cmp(h);if(l===0)return this.negative=0,this.length=1,this.words[0]=0,this;var o,s;l>0?(o=this,s=h):(o=h,s=this);for(var d=0,g=0;g<s.length;g++)y=(o.words[g]|0)-(s.words[g]|0)+d,d=y>>26,this.words[g]=y&67108863;for(;d!==0&&g<o.length;g++)y=(o.words[g]|0)+d,d=y>>26,this.words[g]=y&67108863;if(d===0&&g<o.length&&o!==this)for(;g<o.length;g++)this.words[g]=o.words[g];return this.length=Math.max(this.length,g),o!==this&&(this.negative=1),this.strip()},i.prototype.sub=function(h){return this.clone().isub(h)};function C(M,h,y){y.negative=h.negative^M.negative;var l=M.length+h.length|0;y.length=l,l=l-1|0;var o=M.words[0]|0,s=h.words[0]|0,d=o*s,g=d&67108863,p=d/67108864|0;y.words[0]=g;for(var u=1;u<l;u++){for(var b=p>>>26,_=p&67108863,c=Math.min(u,h.length-1),x=Math.max(0,u-M.length+1);x<=c;x++){var P=u-x|0;o=M.words[P]|0,s=h.words[x]|0,d=o*s+_,b+=d/67108864|0,_=d&67108863}y.words[u]=_|0,p=b|0}return p!==0?y.words[u]=p|0:y.length--,y.strip()}var j=function(h,y,l){var o=h.words,s=y.words,d=l.words,g=0,p,u,b,_=o[0]|0,c=_&8191,x=_>>>13,P=o[1]|0,N=P&8191,U=P>>>13,W=o[2]|0,K=W&8191,G=W>>>13,It=o[3]|0,Z=It&8191,Y=It>>>13,Tn=o[4]|0,Q=Tn&8191,ee=Tn>>>13,Cn=o[5]|0,te=Cn&8191,re=Cn>>>13,On=o[6]|0,ie=On&8191,ne=On>>>13,Pn=o[7]|0,ae=Pn&8191,oe=Pn>>>13,Dn=o[8]|0,fe=Dn&8191,se=Dn>>>13,Un=o[9]|0,ue=Un&8191,he=Un>>>13,Nn=s[0]|0,le=Nn&8191,ce=Nn>>>13,Ln=s[1]|0,de=Ln&8191,pe=Ln>>>13,Fn=s[2]|0,ve=Fn&8191,ye=Fn>>>13,jn=s[3]|0,ge=jn&8191,me=jn>>>13,Hn=s[4]|0,be=Hn&8191,we=Hn>>>13,Kn=s[5]|0,_e=Kn&8191,xe=Kn>>>13,Wn=s[6]|0,Me=Wn&8191,Ee=Wn>>>13,zn=s[7]|0,Se=zn&8191,Be=zn>>>13,Gn=s[8]|0,Ae=Gn&8191,Re=Gn>>>13,Vn=s[9]|0,qe=Vn&8191,Ie=Vn>>>13;l.negative=h.negative^y.negative,l.length=19,p=Math.imul(c,le),u=Math.imul(c,ce),u=u+Math.imul(x,le)|0,b=Math.imul(x,ce);var Ui=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Ui>>>26)|0,Ui&=67108863,p=Math.imul(N,le),u=Math.imul(N,ce),u=u+Math.imul(U,le)|0,b=Math.imul(U,ce),p=p+Math.imul(c,de)|0,u=u+Math.imul(c,pe)|0,u=u+Math.imul(x,de)|0,b=b+Math.imul(x,pe)|0;var Ge=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Ge>>>26)|0,Ge&=67108863,p=Math.imul(K,le),u=Math.imul(K,ce),u=u+Math.imul(G,le)|0,b=Math.imul(G,ce),p=p+Math.imul(N,de)|0,u=u+Math.imul(N,pe)|0,u=u+Math.imul(U,de)|0,b=b+Math.imul(U,pe)|0,p=p+Math.imul(c,ve)|0,u=u+Math.imul(c,ye)|0,u=u+Math.imul(x,ve)|0,b=b+Math.imul(x,ye)|0;var Ve=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Ve>>>26)|0,Ve&=67108863,p=Math.imul(Z,le),u=Math.imul(Z,ce),u=u+Math.imul(Y,le)|0,b=Math.imul(Y,ce),p=p+Math.imul(K,de)|0,u=u+Math.imul(K,pe)|0,u=u+Math.imul(G,de)|0,b=b+Math.imul(G,pe)|0,p=p+Math.imul(N,ve)|0,u=u+Math.imul(N,ye)|0,u=u+Math.imul(U,ve)|0,b=b+Math.imul(U,ye)|0,p=p+Math.imul(c,ge)|0,u=u+Math.imul(c,me)|0,u=u+Math.imul(x,ge)|0,b=b+Math.imul(x,me)|0;var Kr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Kr>>>26)|0,Kr&=67108863,p=Math.imul(Q,le),u=Math.imul(Q,ce),u=u+Math.imul(ee,le)|0,b=Math.imul(ee,ce),p=p+Math.imul(Z,de)|0,u=u+Math.imul(Z,pe)|0,u=u+Math.imul(Y,de)|0,b=b+Math.imul(Y,pe)|0,p=p+Math.imul(K,ve)|0,u=u+Math.imul(K,ye)|0,u=u+Math.imul(G,ve)|0,b=b+Math.imul(G,ye)|0,p=p+Math.imul(N,ge)|0,u=u+Math.imul(N,me)|0,u=u+Math.imul(U,ge)|0,b=b+Math.imul(U,me)|0,p=p+Math.imul(c,be)|0,u=u+Math.imul(c,we)|0,u=u+Math.imul(x,be)|0,b=b+Math.imul(x,we)|0;var Wr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Wr>>>26)|0,Wr&=67108863,p=Math.imul(te,le),u=Math.imul(te,ce),u=u+Math.imul(re,le)|0,b=Math.imul(re,ce),p=p+Math.imul(Q,de)|0,u=u+Math.imul(Q,pe)|0,u=u+Math.imul(ee,de)|0,b=b+Math.imul(ee,pe)|0,p=p+Math.imul(Z,ve)|0,u=u+Math.imul(Z,ye)|0,u=u+Math.imul(Y,ve)|0,b=b+Math.imul(Y,ye)|0,p=p+Math.imul(K,ge)|0,u=u+Math.imul(K,me)|0,u=u+Math.imul(G,ge)|0,b=b+Math.imul(G,me)|0,p=p+Math.imul(N,be)|0,u=u+Math.imul(N,we)|0,u=u+Math.imul(U,be)|0,b=b+Math.imul(U,we)|0,p=p+Math.imul(c,_e)|0,u=u+Math.imul(c,xe)|0,u=u+Math.imul(x,_e)|0,b=b+Math.imul(x,xe)|0;var zr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(zr>>>26)|0,zr&=67108863,p=Math.imul(ie,le),u=Math.imul(ie,ce),u=u+Math.imul(ne,le)|0,b=Math.imul(ne,ce),p=p+Math.imul(te,de)|0,u=u+Math.imul(te,pe)|0,u=u+Math.imul(re,de)|0,b=b+Math.imul(re,pe)|0,p=p+Math.imul(Q,ve)|0,u=u+Math.imul(Q,ye)|0,u=u+Math.imul(ee,ve)|0,b=b+Math.imul(ee,ye)|0,p=p+Math.imul(Z,ge)|0,u=u+Math.imul(Z,me)|0,u=u+Math.imul(Y,ge)|0,b=b+Math.imul(Y,me)|0,p=p+Math.imul(K,be)|0,u=u+Math.imul(K,we)|0,u=u+Math.imul(G,be)|0,b=b+Math.imul(G,we)|0,p=p+Math.imul(N,_e)|0,u=u+Math.imul(N,xe)|0,u=u+Math.imul(U,_e)|0,b=b+Math.imul(U,xe)|0,p=p+Math.imul(c,Me)|0,u=u+Math.imul(c,Ee)|0,u=u+Math.imul(x,Me)|0,b=b+Math.imul(x,Ee)|0;var Gr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Gr>>>26)|0,Gr&=67108863,p=Math.imul(ae,le),u=Math.imul(ae,ce),u=u+Math.imul(oe,le)|0,b=Math.imul(oe,ce),p=p+Math.imul(ie,de)|0,u=u+Math.imul(ie,pe)|0,u=u+Math.imul(ne,de)|0,b=b+Math.imul(ne,pe)|0,p=p+Math.imul(te,ve)|0,u=u+Math.imul(te,ye)|0,u=u+Math.imul(re,ve)|0,b=b+Math.imul(re,ye)|0,p=p+Math.imul(Q,ge)|0,u=u+Math.imul(Q,me)|0,u=u+Math.imul(ee,ge)|0,b=b+Math.imul(ee,me)|0,p=p+Math.imul(Z,be)|0,u=u+Math.imul(Z,we)|0,u=u+Math.imul(Y,be)|0,b=b+Math.imul(Y,we)|0,p=p+Math.imul(K,_e)|0,u=u+Math.imul(K,xe)|0,u=u+Math.imul(G,_e)|0,b=b+Math.imul(G,xe)|0,p=p+Math.imul(N,Me)|0,u=u+Math.imul(N,Ee)|0,u=u+Math.imul(U,Me)|0,b=b+Math.imul(U,Ee)|0,p=p+Math.imul(c,Se)|0,u=u+Math.imul(c,Be)|0,u=u+Math.imul(x,Se)|0,b=b+Math.imul(x,Be)|0;var Vr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Vr>>>26)|0,Vr&=67108863,p=Math.imul(fe,le),u=Math.imul(fe,ce),u=u+Math.imul(se,le)|0,b=Math.imul(se,ce),p=p+Math.imul(ae,de)|0,u=u+Math.imul(ae,pe)|0,u=u+Math.imul(oe,de)|0,b=b+Math.imul(oe,pe)|0,p=p+Math.imul(ie,ve)|0,u=u+Math.imul(ie,ye)|0,u=u+Math.imul(ne,ve)|0,b=b+Math.imul(ne,ye)|0,p=p+Math.imul(te,ge)|0,u=u+Math.imul(te,me)|0,u=u+Math.imul(re,ge)|0,b=b+Math.imul(re,me)|0,p=p+Math.imul(Q,be)|0,u=u+Math.imul(Q,we)|0,u=u+Math.imul(ee,be)|0,b=b+Math.imul(ee,we)|0,p=p+Math.imul(Z,_e)|0,u=u+Math.imul(Z,xe)|0,u=u+Math.imul(Y,_e)|0,b=b+Math.imul(Y,xe)|0,p=p+Math.imul(K,Me)|0,u=u+Math.imul(K,Ee)|0,u=u+Math.imul(G,Me)|0,b=b+Math.imul(G,Ee)|0,p=p+Math.imul(N,Se)|0,u=u+Math.imul(N,Be)|0,u=u+Math.imul(U,Se)|0,b=b+Math.imul(U,Be)|0,p=p+Math.imul(c,Ae)|0,u=u+Math.imul(c,Re)|0,u=u+Math.imul(x,Ae)|0,b=b+Math.imul(x,Re)|0;var $r=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+($r>>>26)|0,$r&=67108863,p=Math.imul(ue,le),u=Math.imul(ue,ce),u=u+Math.imul(he,le)|0,b=Math.imul(he,ce),p=p+Math.imul(fe,de)|0,u=u+Math.imul(fe,pe)|0,u=u+Math.imul(se,de)|0,b=b+Math.imul(se,pe)|0,p=p+Math.imul(ae,ve)|0,u=u+Math.imul(ae,ye)|0,u=u+Math.imul(oe,ve)|0,b=b+Math.imul(oe,ye)|0,p=p+Math.imul(ie,ge)|0,u=u+Math.imul(ie,me)|0,u=u+Math.imul(ne,ge)|0,b=b+Math.imul(ne,me)|0,p=p+Math.imul(te,be)|0,u=u+Math.imul(te,we)|0,u=u+Math.imul(re,be)|0,b=b+Math.imul(re,we)|0,p=p+Math.imul(Q,_e)|0,u=u+Math.imul(Q,xe)|0,u=u+Math.imul(ee,_e)|0,b=b+Math.imul(ee,xe)|0,p=p+Math.imul(Z,Me)|0,u=u+Math.imul(Z,Ee)|0,u=u+Math.imul(Y,Me)|0,b=b+Math.imul(Y,Ee)|0,p=p+Math.imul(K,Se)|0,u=u+Math.imul(K,Be)|0,u=u+Math.imul(G,Se)|0,b=b+Math.imul(G,Be)|0,p=p+Math.imul(N,Ae)|0,u=u+Math.imul(N,Re)|0,u=u+Math.imul(U,Ae)|0,b=b+Math.imul(U,Re)|0,p=p+Math.imul(c,qe)|0,u=u+Math.imul(c,Ie)|0,u=u+Math.imul(x,qe)|0,b=b+Math.imul(x,Ie)|0;var Zr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Zr>>>26)|0,Zr&=67108863,p=Math.imul(ue,de),u=Math.imul(ue,pe),u=u+Math.imul(he,de)|0,b=Math.imul(he,pe),p=p+Math.imul(fe,ve)|0,u=u+Math.imul(fe,ye)|0,u=u+Math.imul(se,ve)|0,b=b+Math.imul(se,ye)|0,p=p+Math.imul(ae,ge)|0,u=u+Math.imul(ae,me)|0,u=u+Math.imul(oe,ge)|0,b=b+Math.imul(oe,me)|0,p=p+Math.imul(ie,be)|0,u=u+Math.imul(ie,we)|0,u=u+Math.imul(ne,be)|0,b=b+Math.imul(ne,we)|0,p=p+Math.imul(te,_e)|0,u=u+Math.imul(te,xe)|0,u=u+Math.imul(re,_e)|0,b=b+Math.imul(re,xe)|0,p=p+Math.imul(Q,Me)|0,u=u+Math.imul(Q,Ee)|0,u=u+Math.imul(ee,Me)|0,b=b+Math.imul(ee,Ee)|0,p=p+Math.imul(Z,Se)|0,u=u+Math.imul(Z,Be)|0,u=u+Math.imul(Y,Se)|0,b=b+Math.imul(Y,Be)|0,p=p+Math.imul(K,Ae)|0,u=u+Math.imul(K,Re)|0,u=u+Math.imul(G,Ae)|0,b=b+Math.imul(G,Re)|0,p=p+Math.imul(N,qe)|0,u=u+Math.imul(N,Ie)|0,u=u+Math.imul(U,qe)|0,b=b+Math.imul(U,Ie)|0;var Yr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Yr>>>26)|0,Yr&=67108863,p=Math.imul(ue,ve),u=Math.imul(ue,ye),u=u+Math.imul(he,ve)|0,b=Math.imul(he,ye),p=p+Math.imul(fe,ge)|0,u=u+Math.imul(fe,me)|0,u=u+Math.imul(se,ge)|0,b=b+Math.imul(se,me)|0,p=p+Math.imul(ae,be)|0,u=u+Math.imul(ae,we)|0,u=u+Math.imul(oe,be)|0,b=b+Math.imul(oe,we)|0,p=p+Math.imul(ie,_e)|0,u=u+Math.imul(ie,xe)|0,u=u+Math.imul(ne,_e)|0,b=b+Math.imul(ne,xe)|0,p=p+Math.imul(te,Me)|0,u=u+Math.imul(te,Ee)|0,u=u+Math.imul(re,Me)|0,b=b+Math.imul(re,Ee)|0,p=p+Math.imul(Q,Se)|0,u=u+Math.imul(Q,Be)|0,u=u+Math.imul(ee,Se)|0,b=b+Math.imul(ee,Be)|0,p=p+Math.imul(Z,Ae)|0,u=u+Math.imul(Z,Re)|0,u=u+Math.imul(Y,Ae)|0,b=b+Math.imul(Y,Re)|0,p=p+Math.imul(K,qe)|0,u=u+Math.imul(K,Ie)|0,u=u+Math.imul(G,qe)|0,b=b+Math.imul(G,Ie)|0;var Xr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Xr>>>26)|0,Xr&=67108863,p=Math.imul(ue,ge),u=Math.imul(ue,me),u=u+Math.imul(he,ge)|0,b=Math.imul(he,me),p=p+Math.imul(fe,be)|0,u=u+Math.imul(fe,we)|0,u=u+Math.imul(se,be)|0,b=b+Math.imul(se,we)|0,p=p+Math.imul(ae,_e)|0,u=u+Math.imul(ae,xe)|0,u=u+Math.imul(oe,_e)|0,b=b+Math.imul(oe,xe)|0,p=p+Math.imul(ie,Me)|0,u=u+Math.imul(ie,Ee)|0,u=u+Math.imul(ne,Me)|0,b=b+Math.imul(ne,Ee)|0,p=p+Math.imul(te,Se)|0,u=u+Math.imul(te,Be)|0,u=u+Math.imul(re,Se)|0,b=b+Math.imul(re,Be)|0,p=p+Math.imul(Q,Ae)|0,u=u+Math.imul(Q,Re)|0,u=u+Math.imul(ee,Ae)|0,b=b+Math.imul(ee,Re)|0,p=p+Math.imul(Z,qe)|0,u=u+Math.imul(Z,Ie)|0,u=u+Math.imul(Y,qe)|0,b=b+Math.imul(Y,Ie)|0;var Jr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Jr>>>26)|0,Jr&=67108863,p=Math.imul(ue,be),u=Math.imul(ue,we),u=u+Math.imul(he,be)|0,b=Math.imul(he,we),p=p+Math.imul(fe,_e)|0,u=u+Math.imul(fe,xe)|0,u=u+Math.imul(se,_e)|0,b=b+Math.imul(se,xe)|0,p=p+Math.imul(ae,Me)|0,u=u+Math.imul(ae,Ee)|0,u=u+Math.imul(oe,Me)|0,b=b+Math.imul(oe,Ee)|0,p=p+Math.imul(ie,Se)|0,u=u+Math.imul(ie,Be)|0,u=u+Math.imul(ne,Se)|0,b=b+Math.imul(ne,Be)|0,p=p+Math.imul(te,Ae)|0,u=u+Math.imul(te,Re)|0,u=u+Math.imul(re,Ae)|0,b=b+Math.imul(re,Re)|0,p=p+Math.imul(Q,qe)|0,u=u+Math.imul(Q,Ie)|0,u=u+Math.imul(ee,qe)|0,b=b+Math.imul(ee,Ie)|0;var Qr=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(Qr>>>26)|0,Qr&=67108863,p=Math.imul(ue,_e),u=Math.imul(ue,xe),u=u+Math.imul(he,_e)|0,b=Math.imul(he,xe),p=p+Math.imul(fe,Me)|0,u=u+Math.imul(fe,Ee)|0,u=u+Math.imul(se,Me)|0,b=b+Math.imul(se,Ee)|0,p=p+Math.imul(ae,Se)|0,u=u+Math.imul(ae,Be)|0,u=u+Math.imul(oe,Se)|0,b=b+Math.imul(oe,Be)|0,p=p+Math.imul(ie,Ae)|0,u=u+Math.imul(ie,Re)|0,u=u+Math.imul(ne,Ae)|0,b=b+Math.imul(ne,Re)|0,p=p+Math.imul(te,qe)|0,u=u+Math.imul(te,Ie)|0,u=u+Math.imul(re,qe)|0,b=b+Math.imul(re,Ie)|0;var ei=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ei>>>26)|0,ei&=67108863,p=Math.imul(ue,Me),u=Math.imul(ue,Ee),u=u+Math.imul(he,Me)|0,b=Math.imul(he,Ee),p=p+Math.imul(fe,Se)|0,u=u+Math.imul(fe,Be)|0,u=u+Math.imul(se,Se)|0,b=b+Math.imul(se,Be)|0,p=p+Math.imul(ae,Ae)|0,u=u+Math.imul(ae,Re)|0,u=u+Math.imul(oe,Ae)|0,b=b+Math.imul(oe,Re)|0,p=p+Math.imul(ie,qe)|0,u=u+Math.imul(ie,Ie)|0,u=u+Math.imul(ne,qe)|0,b=b+Math.imul(ne,Ie)|0;var ti=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ti>>>26)|0,ti&=67108863,p=Math.imul(ue,Se),u=Math.imul(ue,Be),u=u+Math.imul(he,Se)|0,b=Math.imul(he,Be),p=p+Math.imul(fe,Ae)|0,u=u+Math.imul(fe,Re)|0,u=u+Math.imul(se,Ae)|0,b=b+Math.imul(se,Re)|0,p=p+Math.imul(ae,qe)|0,u=u+Math.imul(ae,Ie)|0,u=u+Math.imul(oe,qe)|0,b=b+Math.imul(oe,Ie)|0;var ri=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ri>>>26)|0,ri&=67108863,p=Math.imul(ue,Ae),u=Math.imul(ue,Re),u=u+Math.imul(he,Ae)|0,b=Math.imul(he,Re),p=p+Math.imul(fe,qe)|0,u=u+Math.imul(fe,Ie)|0,u=u+Math.imul(se,qe)|0,b=b+Math.imul(se,Ie)|0;var ii=(g+p|0)+((u&8191)<<13)|0;g=(b+(u>>>13)|0)+(ii>>>26)|0,ii&=67108863,p=Math.imul(ue,qe),u=Math.imul(ue,Ie),u=u+Math.imul(he,qe)|0,b=Math.imul(he,Ie);var ni=(g+p|0)+((u&8191)<<13)|0;return g=(b+(u>>>13)|0)+(ni>>>26)|0,ni&=67108863,d[0]=Ui,d[1]=Ge,d[2]=Ve,d[3]=Kr,d[4]=Wr,d[5]=zr,d[6]=Gr,d[7]=Vr,d[8]=$r,d[9]=Zr,d[10]=Yr,d[11]=Xr,d[12]=Jr,d[13]=Qr,d[14]=ei,d[15]=ti,d[16]=ri,d[17]=ii,d[18]=ni,g!==0&&(d[19]=g,l.length++),l};Math.imul||(j=C);function V(M,h,y){y.negative=h.negative^M.negative,y.length=M.length+h.length;for(var l=0,o=0,s=0;s<y.length-1;s++){var d=o;o=0;for(var g=l&67108863,p=Math.min(s,h.length-1),u=Math.max(0,s-M.length+1);u<=p;u++){var b=s-u,_=M.words[b]|0,c=h.words[u]|0,x=_*c,P=x&67108863;d=d+(x/67108864|0)|0,P=P+g|0,g=P&67108863,d=d+(P>>>26)|0,o+=d>>>26,d&=67108863}y.words[s]=g,l=d,d=o}return l!==0?y.words[s]=l:y.length--,y.strip()}function X(M,h,y){var l=new z;return l.mulp(M,h,y)}i.prototype.mulTo=function(h,y){var l,o=this.length+h.length;return this.length===10&&h.length===10?l=j(this,h,y):o<63?l=C(this,h,y):o<1024?l=V(this,h,y):l=X(this,h,y),l};function z(M,h){this.x=M,this.y=h}z.prototype.makeRBT=function(h){for(var y=new Array(h),l=i.prototype._countBits(h)-1,o=0;o<h;o++)y[o]=this.revBin(o,l,h);return y},z.prototype.revBin=function(h,y,l){if(h===0||h===l-1)return h;for(var o=0,s=0;s<y;s++)o|=(h&1)<<y-s-1,h>>=1;return o},z.prototype.permute=function(h,y,l,o,s,d){for(var g=0;g<d;g++)o[g]=y[h[g]],s[g]=l[h[g]]},z.prototype.transform=function(h,y,l,o,s,d){this.permute(d,h,y,l,o,s);for(var g=1;g<s;g<<=1)for(var p=g<<1,u=Math.cos(2*Math.PI/p),b=Math.sin(2*Math.PI/p),_=0;_<s;_+=p)for(var c=u,x=b,P=0;P<g;P++){var N=l[_+P],U=o[_+P],W=l[_+P+g],K=o[_+P+g],G=c*W-x*K;K=c*K+x*W,W=G,l[_+P]=N+W,o[_+P]=U+K,l[_+P+g]=N-W,o[_+P+g]=U-K,P!==p&&(G=u*c-b*x,x=u*x+b*c,c=G)}},z.prototype.guessLen13b=function(h,y){var l=Math.max(y,h)|1,o=l&1,s=0;for(l=l/2|0;l;l=l>>>1)s++;return 1<<s+1+o},z.prototype.conjugate=function(h,y,l){if(!(l<=1))for(var o=0;o<l/2;o++){var s=h[o];h[o]=h[l-o-1],h[l-o-1]=s,s=y[o],y[o]=-y[l-o-1],y[l-o-1]=-s}},z.prototype.normalize13b=function(h,y){for(var l=0,o=0;o<y/2;o++){var s=Math.round(h[2*o+1]/y)*8192+Math.round(h[2*o]/y)+l;h[o]=s&67108863,s<67108864?l=0:l=s/67108864|0}return h},z.prototype.convert13b=function(h,y,l,o){for(var s=0,d=0;d<y;d++)s=s+(h[d]|0),l[2*d]=s&8191,s=s>>>13,l[2*d+1]=s&8191,s=s>>>13;for(d=2*y;d<o;++d)l[d]=0;r(s===0),r((s&-8192)===0)},z.prototype.stub=function(h){for(var y=new Array(h),l=0;l<h;l++)y[l]=0;return y},z.prototype.mulp=function(h,y,l){var o=2*this.guessLen13b(h.length,y.length),s=this.makeRBT(o),d=this.stub(o),g=new Array(o),p=new Array(o),u=new Array(o),b=new Array(o),_=new Array(o),c=new Array(o),x=l.words;x.length=o,this.convert13b(h.words,h.length,g,o),this.convert13b(y.words,y.length,b,o),this.transform(g,d,p,u,o,s),this.transform(b,d,_,c,o,s);for(var P=0;P<o;P++){var N=p[P]*_[P]-u[P]*c[P];u[P]=p[P]*c[P]+u[P]*_[P],p[P]=N}return this.conjugate(p,u,o),this.transform(p,u,x,d,o,s),this.conjugate(x,d,o),this.normalize13b(x,o),l.negative=h.negative^y.negative,l.length=h.length+y.length,l.strip()},i.prototype.mul=function(h){var y=new i(null);return y.words=new Array(this.length+h.length),this.mulTo(h,y)},i.prototype.mulf=function(h){var y=new i(null);return y.words=new Array(this.length+h.length),X(this,h,y)},i.prototype.imul=function(h){return this.clone().mulTo(h,this)},i.prototype.imuln=function(h){r(typeof h=="number"),r(h<67108864);for(var y=0,l=0;l<this.length;l++){var o=(this.words[l]|0)*h,s=(o&67108863)+(y&67108863);y>>=26,y+=o/67108864|0,y+=s>>>26,this.words[l]=s&67108863}return y!==0&&(this.words[l]=y,this.length++),h===0&&(this.length=1,this._normSign()),this},i.prototype.muln=function(h){return this.clone().imuln(h)},i.prototype.sqr=function(){return this.mul(this)},i.prototype.isqr=function(){return this.imul(this.clone())},i.prototype.pow=function(h){var y=I(h);if(y.length===0)return new i(1);for(var l=this,o=0;o<y.length&&y[o]===0;o++,l=l.sqr());if(++o<y.length)for(var s=l.sqr();o<y.length;o++,s=s.sqr())y[o]!==0&&(l=l.mul(s));return l},i.prototype.iushln=function(h){r(typeof h=="number"&&h>=0);var y=h%26,l=(h-y)/26,o=67108863>>>26-y<<26-y,s;if(y!==0){var d=0;for(s=0;s<this.length;s++){var g=this.words[s]&o,p=(this.words[s]|0)-g<<y;this.words[s]=p|d,d=g>>>26-y}d&&(this.words[s]=d,this.length++)}if(l!==0){for(s=this.length-1;s>=0;s--)this.words[s+l]=this.words[s];for(s=0;s<l;s++)this.words[s]=0;this.length+=l}return this.strip()},i.prototype.ishln=function(h){return r(this.negative===0),this.iushln(h)},i.prototype.iushrn=function(h,y,l){r(typeof h=="number"&&h>=0);var o;y?o=(y-y%26)/26:o=0;var s=h%26,d=Math.min((h-s)/26,this.length),g=67108863^67108863>>>s<<s,p=l;if(o-=d,o=Math.max(0,o),p){for(var u=0;u<d;u++)p.words[u]=this.words[u];p.length=d}if(d!==0)if(this.length>d)for(this.length-=d,u=0;u<this.length;u++)this.words[u]=this.words[u+d];else this.words[0]=0,this.length=1;var b=0;for(u=this.length-1;u>=0&&(b!==0||u>=o);u--){var _=this.words[u]|0;this.words[u]=b<<26-s|_>>>s,b=_&g}return p&&b!==0&&(p.words[p.length++]=b),this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.ishrn=function(h,y,l){return r(this.negative===0),this.iushrn(h,y,l)},i.prototype.shln=function(h){return this.clone().ishln(h)},i.prototype.ushln=function(h){return this.clone().iushln(h)},i.prototype.shrn=function(h){return this.clone().ishrn(h)},i.prototype.ushrn=function(h){return this.clone().iushrn(h)},i.prototype.testn=function(h){r(typeof h=="number"&&h>=0);var y=h%26,l=(h-y)/26,o=1<<y;if(this.length<=l)return!1;var s=this.words[l];return!!(s&o)},i.prototype.imaskn=function(h){r(typeof h=="number"&&h>=0);var y=h%26,l=(h-y)/26;if(r(this.negative===0,"imaskn works only with positive numbers"),this.length<=l)return this;if(y!==0&&l++,this.length=Math.min(l,this.length),y!==0){var o=67108863^67108863>>>y<<y;this.words[this.length-1]&=o}return this.length===0&&(this.words[0]=0,this.length=1),this.strip()},i.prototype.maskn=function(h){return this.clone().imaskn(h)},i.prototype.iaddn=function(h){return r(typeof h=="number"),r(h<67108864),h<0?this.isubn(-h):this.negative!==0?this.length===1&&(this.words[0]|0)<h?(this.words[0]=h-(this.words[0]|0),this.negative=0,this):(this.negative=0,this.isubn(h),this.negative=1,this):this._iaddn(h)},i.prototype._iaddn=function(h){this.words[0]+=h;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},i.prototype.isubn=function(h){if(r(typeof h=="number"),r(h<67108864),h<0)return this.iaddn(-h);if(this.negative!==0)return this.negative=0,this.iaddn(h),this.negative=1,this;if(this.words[0]-=h,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()},i.prototype.addn=function(h){return this.clone().iaddn(h)},i.prototype.subn=function(h){return this.clone().isubn(h)},i.prototype.iabs=function(){return this.negative=0,this},i.prototype.abs=function(){return this.clone().iabs()},i.prototype._ishlnsubmul=function(h,y,l){var o=h.length+l,s;this._expand(o);var d,g=0;for(s=0;s<h.length;s++){d=(this.words[s+l]|0)+g;var p=(h.words[s]|0)*y;d-=p&67108863,g=(d>>26)-(p/67108864|0),this.words[s+l]=d&67108863}for(;s<this.length-l;s++)d=(this.words[s+l]|0)+g,g=d>>26,this.words[s+l]=d&67108863;if(g===0)return this.strip();for(r(g===-1),g=0,s=0;s<this.length;s++)d=-(this.words[s]|0)+g,g=d>>26,this.words[s]=d&67108863;return this.negative=1,this.strip()},i.prototype._wordDiv=function(h,y){var l=this.length-h.length,o=this.clone(),s=h,d=s.words[s.length-1]|0,g=this._countBits(d);l=26-g,l!==0&&(s=s.ushln(l),o.iushln(l),d=s.words[s.length-1]|0);var p=o.length-s.length,u;if(y!=="mod"){u=new i(null),u.length=p+1,u.words=new Array(u.length);for(var b=0;b<u.length;b++)u.words[b]=0}var _=o.clone()._ishlnsubmul(s,1,p);_.negative===0&&(o=_,u&&(u.words[p]=1));for(var c=p-1;c>=0;c--){var x=(o.words[s.length+c]|0)*67108864+(o.words[s.length+c-1]|0);for(x=Math.min(x/d|0,67108863),o._ishlnsubmul(s,x,c);o.negative!==0;)x--,o.negative=0,o._ishlnsubmul(s,1,c),o.isZero()||(o.negative^=1);u&&(u.words[c]=x)}return u&&u.strip(),o.strip(),y!=="div"&&l!==0&&o.iushrn(l),{div:u||null,mod:o}},i.prototype.divmod=function(h,y,l){if(r(!h.isZero()),this.isZero())return{div:new i(0),mod:new i(0)};var o,s,d;return this.negative!==0&&h.negative===0?(d=this.neg().divmod(h,y),y!=="mod"&&(o=d.div.neg()),y!=="div"&&(s=d.mod.neg(),l&&s.negative!==0&&s.iadd(h)),{div:o,mod:s}):this.negative===0&&h.negative!==0?(d=this.divmod(h.neg(),y),y!=="mod"&&(o=d.div.neg()),{div:o,mod:d.mod}):(this.negative&h.negative)!==0?(d=this.neg().divmod(h.neg(),y),y!=="div"&&(s=d.mod.neg(),l&&s.negative!==0&&s.isub(h)),{div:d.div,mod:s}):h.length>this.length||this.cmp(h)<0?{div:new i(0),mod:this}:h.length===1?y==="div"?{div:this.divn(h.words[0]),mod:null}:y==="mod"?{div:null,mod:new i(this.modn(h.words[0]))}:{div:this.divn(h.words[0]),mod:new i(this.modn(h.words[0]))}:this._wordDiv(h,y)},i.prototype.div=function(h){return this.divmod(h,"div",!1).div},i.prototype.mod=function(h){return this.divmod(h,"mod",!1).mod},i.prototype.umod=function(h){return this.divmod(h,"mod",!0).mod},i.prototype.divRound=function(h){var y=this.divmod(h);if(y.mod.isZero())return y.div;var l=y.mod.abs(),o=h.abs().iushrn(1),s=h.words[0]&1,d=l.cmp(o);if(d<0||s===1&&d===0)return y.div;var g=new i(1);return g.negative=this.negative^h.negative,y.div.iadd(g)},i.prototype.modn=function(h){r(h<=67108863);for(var y=(1<<26)%h,l=0,o=this.length-1;o>=0;o--)l=(y*l+(this.words[o]|0))%h;return l},i.prototype.idivn=function(h){r(h<=67108863);for(var y=0,l=this.length-1;l>=0;l--){var o=(this.words[l]|0)+y*67108864;this.words[l]=o/h|0,y=o%h}return this.strip()},i.prototype.divn=function(h){return this.clone().idivn(h)},i.prototype.egcd=function(h){r(h.negative===0),r(!h.isZero());var y=this,l=h.clone();y.negative!==0?y=y.umod(h):y=y.clone();for(var o=new i(1),s=new i(0),d=new i(0),g=new i(1),p=0;y.isEven()&&l.isEven();)y.iushrn(1),l.iushrn(1),++p;for(var u=l.clone(),b=y.clone();!y.isZero();){for(var _=0,c=1;(y.words[0]&c)===0&&_<26;++_,c<<=1);if(_>0)for(y.iushrn(_);_-- >0;)(o.isOdd()||s.isOdd())&&(o.iadd(u),s.isub(b)),o.iushrn(1),s.iushrn(1);for(var x=0,P=1;(l.words[0]&P)===0&&x<26;++x,P<<=1);if(x>0)for(l.iushrn(x);x-- >0;)(d.isOdd()||g.isOdd())&&(d.iadd(u),g.isub(b)),d.iushrn(1),g.iushrn(1);y.cmp(l)>=0?(y.isub(l),o.isub(d),s.isub(g)):(l.isub(y),d.isub(o),g.isub(s))}return{a:d,b:g,gcd:l.iushln(p)}},i.prototype._invmp=function(h){r(h.negative===0),r(!h.isZero());var y=this,l=h.clone();y.negative!==0?y=y.umod(h):y=y.clone();for(var o=new i(1),s=new i(0),d=l.clone();y.cmpn(1)>0&&l.cmpn(1)>0;){for(var g=0,p=1;(y.words[0]&p)===0&&g<26;++g,p<<=1);if(g>0)for(y.iushrn(g);g-- >0;)o.isOdd()&&o.iadd(d),o.iushrn(1);for(var u=0,b=1;(l.words[0]&b)===0&&u<26;++u,b<<=1);if(u>0)for(l.iushrn(u);u-- >0;)s.isOdd()&&s.iadd(d),s.iushrn(1);y.cmp(l)>=0?(y.isub(l),o.isub(s)):(l.isub(y),s.isub(o))}var _;return y.cmpn(1)===0?_=o:_=s,_.cmpn(0)<0&&_.iadd(h),_},i.prototype.gcd=function(h){if(this.isZero())return h.abs();if(h.isZero())return this.abs();var y=this.clone(),l=h.clone();y.negative=0,l.negative=0;for(var o=0;y.isEven()&&l.isEven();o++)y.iushrn(1),l.iushrn(1);do{for(;y.isEven();)y.iushrn(1);for(;l.isEven();)l.iushrn(1);var s=y.cmp(l);if(s<0){var d=y;y=l,l=d}else if(s===0||l.cmpn(1)===0)break;y.isub(l)}while(!0);return l.iushln(o)},i.prototype.invm=function(h){return this.egcd(h).a.umod(h)},i.prototype.isEven=function(){return(this.words[0]&1)===0},i.prototype.isOdd=function(){return(this.words[0]&1)===1},i.prototype.andln=function(h){return this.words[0]&h},i.prototype.bincn=function(h){r(typeof h=="number");var y=h%26,l=(h-y)/26,o=1<<y;if(this.length<=l)return this._expand(l+1),this.words[l]|=o,this;for(var s=o,d=l;s!==0&&d<this.length;d++){var g=this.words[d]|0;g+=s,s=g>>>26,g&=67108863,this.words[d]=g}return s!==0&&(this.words[d]=s,this.length++),this},i.prototype.isZero=function(){return this.length===1&&this.words[0]===0},i.prototype.cmpn=function(h){var y=h<0;if(this.negative!==0&&!y)return-1;if(this.negative===0&&y)return 1;this.strip();var l;if(this.length>1)l=1;else{y&&(h=-h),r(h<=67108863,"Number is too big");var o=this.words[0]|0;l=o===h?0:o<h?-1:1}return this.negative!==0?-l|0:l},i.prototype.cmp=function(h){if(this.negative!==0&&h.negative===0)return-1;if(this.negative===0&&h.negative!==0)return 1;var y=this.ucmp(h);return this.negative!==0?-y|0:y},i.prototype.ucmp=function(h){if(this.length>h.length)return 1;if(this.length<h.length)return-1;for(var y=0,l=this.length-1;l>=0;l--){var o=this.words[l]|0,s=h.words[l]|0;if(o!==s){o<s?y=-1:o>s&&(y=1);break}}return y},i.prototype.gtn=function(h){return this.cmpn(h)===1},i.prototype.gt=function(h){return this.cmp(h)===1},i.prototype.gten=function(h){return this.cmpn(h)>=0},i.prototype.gte=function(h){return this.cmp(h)>=0},i.prototype.ltn=function(h){return this.cmpn(h)===-1},i.prototype.lt=function(h){return this.cmp(h)===-1},i.prototype.lten=function(h){return this.cmpn(h)<=0},i.prototype.lte=function(h){return this.cmp(h)<=0},i.prototype.eqn=function(h){return this.cmpn(h)===0},i.prototype.eq=function(h){return this.cmp(h)===0},i.red=function(h){return new F(h)},i.prototype.toRed=function(h){return r(!this.red,"Already a number in reduction context"),r(this.negative===0,"red works only with positives"),h.convertTo(this)._forceRed(h)},i.prototype.fromRed=function(){return r(this.red,"fromRed works only with numbers in reduction context"),this.red.convertFrom(this)},i.prototype._forceRed=function(h){return this.red=h,this},i.prototype.forceRed=function(h){return r(!this.red,"Already a number in reduction context"),this._forceRed(h)},i.prototype.redAdd=function(h){return r(this.red,"redAdd works only with red numbers"),this.red.add(this,h)},i.prototype.redIAdd=function(h){return r(this.red,"redIAdd works only with red numbers"),this.red.iadd(this,h)},i.prototype.redSub=function(h){return r(this.red,"redSub works only with red numbers"),this.red.sub(this,h)},i.prototype.redISub=function(h){return r(this.red,"redISub works only with red numbers"),this.red.isub(this,h)},i.prototype.redShl=function(h){return r(this.red,"redShl works only with red numbers"),this.red.shl(this,h)},i.prototype.redMul=function(h){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,h),this.red.mul(this,h)},i.prototype.redIMul=function(h){return r(this.red,"redMul works only with red numbers"),this.red._verify2(this,h),this.red.imul(this,h)},i.prototype.redSqr=function(){return r(this.red,"redSqr works only with red numbers"),this.red._verify1(this),this.red.sqr(this)},i.prototype.redISqr=function(){return r(this.red,"redISqr works only with red numbers"),this.red._verify1(this),this.red.isqr(this)},i.prototype.redSqrt=function(){return r(this.red,"redSqrt works only with red numbers"),this.red._verify1(this),this.red.sqrt(this)},i.prototype.redInvm=function(){return r(this.red,"redInvm works only with red numbers"),this.red._verify1(this),this.red.invm(this)},i.prototype.redNeg=function(){return r(this.red,"redNeg works only with red numbers"),this.red._verify1(this),this.red.neg(this)},i.prototype.redPow=function(h){return r(this.red&&!h.red,"redPow(normalNum)"),this.red._verify1(this),this.red.pow(this,h)};var $={k256:null,p224:null,p192:null,p25519:null};function Fe(M,h){this.name=M,this.p=new i(h,16),this.n=this.p.bitLength(),this.k=new i(1).iushln(this.n).isub(this.p),this.tmp=this._tmp()}Fe.prototype._tmp=function(){var h=new i(null);return h.words=new Array(Math.ceil(this.n/13)),h},Fe.prototype.ireduce=function(h){var y=h,l;do this.split(y,this.tmp),y=this.imulK(y),y=y.iadd(this.tmp),l=y.bitLength();while(l>this.n);var o=l<this.n?-1:y.ucmp(this.p);return o===0?(y.words[0]=0,y.length=1):o>0?y.isub(this.p):y.strip!==void 0?y.strip():y._strip(),y},Fe.prototype.split=function(h,y){h.iushrn(this.n,0,y)},Fe.prototype.imulK=function(h){return h.imul(this.k)};function k(){Fe.call(this,"k256","ffffffff ffffffff ffffffff ffffffff ffffffff ffffffff fffffffe fffffc2f")}n(k,Fe),k.prototype.split=function(h,y){for(var l=4194303,o=Math.min(h.length,9),s=0;s<o;s++)y.words[s]=h.words[s];if(y.length=o,h.length<=9){h.words[0]=0,h.length=1;return}var d=h.words[9];for(y.words[y.length++]=d&l,s=10;s<h.length;s++){var g=h.words[s]|0;h.words[s-10]=(g&l)<<4|d>>>22,d=g}d>>>=22,h.words[s-10]=d,d===0&&h.length>10?h.length-=10:h.length-=9},k.prototype.imulK=function(h){h.words[h.length]=0,h.words[h.length+1]=0,h.length+=2;for(var y=0,l=0;l<h.length;l++){var o=h.words[l]|0;y+=o*977,h.words[l]=y&67108863,y=o*64+(y/67108864|0)}return h.words[h.length-1]===0&&(h.length--,h.words[h.length-1]===0&&h.length--),h};function O(){Fe.call(this,"p224","ffffffff ffffffff ffffffff ffffffff 00000000 00000000 00000001")}n(O,Fe);function D(){Fe.call(this,"p192","ffffffff ffffffff ffffffff fffffffe ffffffff ffffffff")}n(D,Fe);function L(){Fe.call(this,"25519","7fffffffffffffff ffffffffffffffff ffffffffffffffff ffffffffffffffed")}n(L,Fe),L.prototype.imulK=function(h){for(var y=0,l=0;l<h.length;l++){var o=(h.words[l]|0)*19+y,s=o&67108863;o>>>=26,h.words[l]=s,y=o}return y!==0&&(h.words[h.length++]=y),h},i._prime=function(h){if($[h])return $[h];var y;if(h==="k256")y=new k;else if(h==="p224")y=new O;else if(h==="p192")y=new D;else if(h==="p25519")y=new L;else throw new Error("Unknown prime "+h);return $[h]=y,y};function F(M){if(typeof M=="string"){var h=i._prime(M);this.m=h.p,this.prime=h}else r(M.gtn(1),"modulus must be greater than 1"),this.m=M,this.prime=null}F.prototype._verify1=function(h){r(h.negative===0,"red works only with positives"),r(h.red,"red works only with red numbers")},F.prototype._verify2=function(h,y){r((h.negative|y.negative)===0,"red works only with positives"),r(h.red&&h.red===y.red,"red works only with red numbers")},F.prototype.imod=function(h){return this.prime?this.prime.ireduce(h)._forceRed(this):h.umod(this.m)._forceRed(this)},F.prototype.neg=function(h){return h.isZero()?h.clone():this.m.sub(h)._forceRed(this)},F.prototype.add=function(h,y){this._verify2(h,y);var l=h.add(y);return l.cmp(this.m)>=0&&l.isub(this.m),l._forceRed(this)},F.prototype.iadd=function(h,y){this._verify2(h,y);var l=h.iadd(y);return l.cmp(this.m)>=0&&l.isub(this.m),l},F.prototype.sub=function(h,y){this._verify2(h,y);var l=h.sub(y);return l.cmpn(0)<0&&l.iadd(this.m),l._forceRed(this)},F.prototype.isub=function(h,y){this._verify2(h,y);var l=h.isub(y);return l.cmpn(0)<0&&l.iadd(this.m),l},F.prototype.shl=function(h,y){return this._verify1(h),this.imod(h.ushln(y))},F.prototype.imul=function(h,y){return this._verify2(h,y),this.imod(h.imul(y))},F.prototype.mul=function(h,y){return this._verify2(h,y),this.imod(h.mul(y))},F.prototype.isqr=function(h){return this.imul(h,h.clone())},F.prototype.sqr=function(h){return this.mul(h,h)},F.prototype.sqrt=function(h){if(h.isZero())return h.clone();var y=this.m.andln(3);if(r(y%2===1),y===3){var l=this.m.add(new i(1)).iushrn(2);return this.pow(h,l)}for(var o=this.m.subn(1),s=0;!o.isZero()&&o.andln(1)===0;)s++,o.iushrn(1);r(!o.isZero());var d=new i(1).toRed(this),g=d.redNeg(),p=this.m.subn(1).iushrn(1),u=this.m.bitLength();for(u=new i(2*u*u).toRed(this);this.pow(u,p).cmp(g)!==0;)u.redIAdd(g);for(var b=this.pow(u,o),_=this.pow(h,o.addn(1).iushrn(1)),c=this.pow(h,o),x=s;c.cmp(d)!==0;){for(var P=c,N=0;P.cmp(d)!==0;N++)P=P.redSqr();r(N<x);var U=this.pow(b,new i(1).iushln(x-N-1));_=_.redMul(U),b=U.redSqr(),c=c.redMul(b),x=N}return _},F.prototype.invm=function(h){var y=h._invmp(this.m);return y.negative!==0?(y.negative=0,this.imod(y).redNeg()):this.imod(y)},F.prototype.pow=function(h,y){if(y.isZero())return new i(1).toRed(this);if(y.cmpn(1)===0)return h.clone();var l=4,o=new Array(1<<l);o[0]=new i(1).toRed(this),o[1]=h;for(var s=2;s<o.length;s++)o[s]=this.mul(o[s-1],h);var d=o[0],g=0,p=0,u=y.bitLength()%26;for(u===0&&(u=26),s=y.length-1;s>=0;s--){for(var b=y.words[s],_=u-1;_>=0;_--){var c=b>>_&1;if(d!==o[0]&&(d=this.sqr(d)),c===0&&g===0){p=0;continue}g<<=1,g|=c,p++,!(p!==l&&(s!==0||_!==0))&&(d=this.mul(d,o[g]),p=0,g=0)}u=26}return d},F.prototype.convertTo=function(h){var y=h.umod(this.m);return y===h?y.clone():y},F.prototype.convertFrom=function(h){var y=h.clone();return y.red=null,y},i.mont=function(h){return new H(h)};function H(M){F.call(this,M),this.shift=this.m.bitLength(),this.shift%26!==0&&(this.shift+=26-this.shift%26),this.r=new i(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)}n(H,F),H.prototype.convertTo=function(h){return this.imod(h.ushln(this.shift))},H.prototype.convertFrom=function(h){var y=this.imod(h.mul(this.rinv));return y.red=null,y},H.prototype.imul=function(h,y){if(h.isZero()||y.isZero())return h.words[0]=0,h.length=1,h;var l=h.imul(y),o=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),s=l.isub(o).iushrn(this.shift),d=s;return s.cmp(this.m)>=0?d=s.isub(this.m):s.cmpn(0)<0&&(d=s.iadd(this.m)),d._forceRed(this)},H.prototype.mul=function(h,y){if(h.isZero()||y.isZero())return new i(0)._forceRed(this);var l=h.mul(y),o=l.maskn(this.shift).mul(this.minv).imaskn(this.shift).mul(this.m),s=l.isub(o).iushrn(this.shift),d=s;return s.cmp(this.m)>=0?d=s.isub(this.m):s.cmpn(0)<0&&(d=s.iadd(this.m)),d._forceRed(this)},H.prototype.invm=function(h){var y=this.imod(h._invmp(this.m).mul(this.r2));return y._forceRed(this)}})(typeof cs>"u"||cs,zl)});var ke=R((ds,Vl)=>{w();var Qa=ft(),Zt=Qa.Buffer;function Gl(t,e){for(var r in t)e[r]=t[r]}Zt.from&&Zt.alloc&&Zt.allocUnsafe&&Zt.allocUnsafeSlow?Vl.exports=Qa:(Gl(Qa,ds),ds.Buffer=si);function si(t,e,r){return Zt(t,e,r)}si.prototype=Object.create(Zt.prototype);Gl(Zt,si);si.from=function(t,e,r){if(typeof t=="number")throw new TypeError("Argument must not be a number");return Zt(t,e,r)};si.alloc=function(t,e,r){if(typeof t!="number")throw new TypeError("Argument must be a number");var n=Zt(t);return e!==void 0?typeof r=="string"?n.fill(e,r):n.fill(e):n.fill(0),n};si.allocUnsafe=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return Zt(t)};si.allocUnsafeSlow=function(t){if(typeof t!="number")throw new TypeError("Argument must be a number");return Qa.SlowBuffer(t)}});var ui=R((zB,vs)=>{"use strict";w();var ps=65536,M2=4294967295;function E2(){throw new Error(`Secure random number generation is not supported by this browser.
2
2
  Use Chrome, Firefox or Internet Explorer 11`)}var S2=ke().Buffer,eo=globalThis.crypto||globalThis.msCrypto;eo&&eo.getRandomValues?vs.exports=B2:vs.exports=E2;function B2(t,e){if(t>M2)throw new RangeError("requested too many random bytes");var r=S2.allocUnsafe(t);if(t>0)if(t>ps)for(var n=0;n<t;n+=ps)eo.getRandomValues(r.slice(n,n+ps));else eo.getRandomValues(r);return typeof e=="function"?S.default.nextTick(function(){e(null,r)}):r}});var J=R((VB,ys)=>{w();typeof Object.create=="function"?ys.exports=function(e,r){r&&(e.super_=r,e.prototype=Object.create(r.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}))}:ys.exports=function(e,r){if(r){e.super_=r;var n=function(){};n.prototype=r.prototype,e.prototype=new n,e.prototype.constructor=e}}});var Wi=R((ZB,gs)=>{"use strict";w();var Ki=typeof Reflect=="object"?Reflect:null,$l=Ki&&typeof Ki.apply=="function"?Ki.apply:function(e,r,n){return Function.prototype.apply.call(e,r,n)},to;Ki&&typeof Ki.ownKeys=="function"?to=Ki.ownKeys:Object.getOwnPropertySymbols?to=function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:to=function(e){return Object.getOwnPropertyNames(e)};function A2(t){console&&console.warn&&console.warn(t)}var Yl=Number.isNaN||function(e){return e!==e};function je(){je.init.call(this)}gs.exports=je;gs.exports.once=k2;je.EventEmitter=je;je.prototype._events=void 0;je.prototype._eventsCount=0;je.prototype._maxListeners=void 0;var Zl=10;function ro(t){if(typeof t!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof t)}Object.defineProperty(je,"defaultMaxListeners",{enumerable:!0,get:function(){return Zl},set:function(t){if(typeof t!="number"||t<0||Yl(t))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+t+".");Zl=t}});je.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};je.prototype.setMaxListeners=function(e){if(typeof e!="number"||e<0||Yl(e))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+e+".");return this._maxListeners=e,this};function Xl(t){return t._maxListeners===void 0?je.defaultMaxListeners:t._maxListeners}je.prototype.getMaxListeners=function(){return Xl(this)};je.prototype.emit=function(e){for(var r=[],n=1;n<arguments.length;n++)r.push(arguments[n]);var i=e==="error",a=this._events;if(a!==void 0)i=i&&a.error===void 0;else if(!i)return!1;if(i){var f;if(r.length>0&&(f=r[0]),f instanceof Error)throw f;var v=new Error("Unhandled error."+(f?" ("+f.message+")":""));throw v.context=f,v}var m=a[e];if(m===void 0)return!1;if(typeof m=="function")$l(m,this,r);else for(var E=m.length,A=r0(m,E),n=0;n<E;++n)$l(A[n],this,r);return!0};function Jl(t,e,r,n){var i,a,f;if(ro(r),a=t._events,a===void 0?(a=t._events=Object.create(null),t._eventsCount=0):(a.newListener!==void 0&&(t.emit("newListener",e,r.listener?r.listener:r),a=t._events),f=a[e]),f===void 0)f=a[e]=r,++t._eventsCount;else if(typeof f=="function"?f=a[e]=n?[r,f]:[f,r]:n?f.unshift(r):f.push(r),i=Xl(t),i>0&&f.length>i&&!f.warned){f.warned=!0;var v=new Error("Possible EventEmitter memory leak detected. "+f.length+" "+String(e)+" listeners added. Use emitter.setMaxListeners() to increase limit");v.name="MaxListenersExceededWarning",v.emitter=t,v.type=e,v.count=f.length,A2(v)}return t}je.prototype.addListener=function(e,r){return Jl(this,e,r,!1)};je.prototype.on=je.prototype.addListener;je.prototype.prependListener=function(e,r){return Jl(this,e,r,!0)};function R2(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function Ql(t,e,r){var n={fired:!1,wrapFn:void 0,target:t,type:e,listener:r},i=R2.bind(n);return i.listener=r,n.wrapFn=i,i}je.prototype.once=function(e,r){return ro(r),this.on(e,Ql(this,e,r)),this};je.prototype.prependOnceListener=function(e,r){return ro(r),this.prependListener(e,Ql(this,e,r)),this};je.prototype.removeListener=function(e,r){var n,i,a,f,v;if(ro(r),i=this._events,i===void 0)return this;if(n=i[e],n===void 0)return this;if(n===r||n.listener===r)--this._eventsCount===0?this._events=Object.create(null):(delete i[e],i.removeListener&&this.emit("removeListener",e,n.listener||r));else if(typeof n!="function"){for(a=-1,f=n.length-1;f>=0;f--)if(n[f]===r||n[f].listener===r){v=n[f].listener,a=f;break}if(a<0)return this;a===0?n.shift():q2(n,a),n.length===1&&(i[e]=n[0]),i.removeListener!==void 0&&this.emit("removeListener",e,v||r)}return this};je.prototype.off=je.prototype.removeListener;je.prototype.removeAllListeners=function(e){var r,n,i;if(n=this._events,n===void 0)return this;if(n.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):n[e]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete n[e]),this;if(arguments.length===0){var a=Object.keys(n),f;for(i=0;i<a.length;++i)f=a[i],f!=="removeListener"&&this.removeAllListeners(f);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(r=n[e],typeof r=="function")this.removeListener(e,r);else if(r!==void 0)for(i=r.length-1;i>=0;i--)this.removeListener(e,r[i]);return this};function e0(t,e,r){var n=t._events;if(n===void 0)return[];var i=n[e];return i===void 0?[]:typeof i=="function"?r?[i.listener||i]:[i]:r?I2(i):r0(i,i.length)}je.prototype.listeners=function(e){return e0(this,e,!0)};je.prototype.rawListeners=function(e){return e0(this,e,!1)};je.listenerCount=function(t,e){return typeof t.listenerCount=="function"?t.listenerCount(e):t0.call(t,e)};je.prototype.listenerCount=t0;function t0(t){var e=this._events;if(e!==void 0){var r=e[t];if(typeof r=="function")return 1;if(r!==void 0)return r.length}return 0}je.prototype.eventNames=function(){return this._eventsCount>0?to(this._events):[]};function r0(t,e){for(var r=new Array(e),n=0;n<e;++n)r[n]=t[n];return r}function q2(t,e){for(;e+1<t.length;e++)t[e]=t[e+1];t.pop()}function I2(t){for(var e=new Array(t.length),r=0;r<e.length;++r)e[r]=t[r].listener||t[r];return e}function k2(t,e){return new Promise(function(r,n){function i(f){t.removeListener(e,a),n(f)}function a(){typeof t.removeListener=="function"&&t.removeListener("error",i),r([].slice.call(arguments))}i0(t,e,a,{once:!0}),e!=="error"&&T2(t,i,{once:!0})})}function T2(t,e,r){typeof t.on=="function"&&i0(t,"error",e,r)}function i0(t,e,r,n){if(typeof t.on=="function")n.once?t.once(e,r):t.on(e,r);else if(typeof t.addEventListener=="function")t.addEventListener(e,function i(a){n.once&&t.removeEventListener(e,i),r(a)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof t)}});var ms=R((XB,n0)=>{w();n0.exports=Wi().EventEmitter});var bs=R((QB,a0)=>{"use strict";w();a0.exports=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},r=Symbol("test"),n=Object(r);if(typeof r=="string"||Object.prototype.toString.call(r)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var i=42;e[r]=i;for(var a in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var f=Object.getOwnPropertySymbols(e);if(f.length!==1||f[0]!==r||!Object.prototype.propertyIsEnumerable.call(e,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var v=Object.getOwnPropertyDescriptor(e,r);if(v.value!==i||v.enumerable!==!0)return!1}return!0}});var Zn=R((t7,o0)=>{"use strict";w();var C2=bs();o0.exports=function(){return C2()&&!!Symbol.toStringTag}});var ws=R((i7,f0)=>{"use strict";w();f0.exports=Object});var u0=R((a7,s0)=>{"use strict";w();s0.exports=Error});var l0=R((f7,h0)=>{"use strict";w();h0.exports=EvalError});var d0=R((u7,c0)=>{"use strict";w();c0.exports=RangeError});var v0=R((l7,p0)=>{"use strict";w();p0.exports=ReferenceError});var _s=R((d7,y0)=>{"use strict";w();y0.exports=SyntaxError});var hi=R((v7,g0)=>{"use strict";w();g0.exports=TypeError});var b0=R((g7,m0)=>{"use strict";w();m0.exports=URIError});var _0=R((b7,w0)=>{"use strict";w();w0.exports=Math.abs});var M0=R((_7,x0)=>{"use strict";w();x0.exports=Math.floor});var S0=R((M7,E0)=>{"use strict";w();E0.exports=Math.max});var A0=R((S7,B0)=>{"use strict";w();B0.exports=Math.min});var q0=R((A7,R0)=>{"use strict";w();R0.exports=Math.pow});var k0=R((q7,I0)=>{"use strict";w();I0.exports=Math.round});var C0=R((k7,T0)=>{"use strict";w();T0.exports=Number.isNaN||function(e){return e!==e}});var P0=R((C7,O0)=>{"use strict";w();var O2=C0();O0.exports=function(e){return O2(e)||e===0?e:e<0?-1:1}});var U0=R((P7,D0)=>{"use strict";w();D0.exports=Object.getOwnPropertyDescriptor});var li=R((U7,N0)=>{"use strict";w();var io=U0();if(io)try{io([],"length")}catch{io=null}N0.exports=io});var Yn=R((L7,L0)=>{"use strict";w();var no=Object.defineProperty||!1;if(no)try{no({},"a",{value:1})}catch{no=!1}L0.exports=no});var H0=R((j7,j0)=>{"use strict";w();var F0=typeof Symbol<"u"&&Symbol,P2=bs();j0.exports=function(){return typeof F0!="function"||typeof Symbol!="function"||typeof F0("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:P2()}});var xs=R((K7,K0)=>{"use strict";w();K0.exports=typeof Reflect<"u"&&Reflect.getPrototypeOf||null});var Ms=R((z7,W0)=>{"use strict";w();var D2=ws();W0.exports=D2.getPrototypeOf||null});var V0=R((V7,G0)=>{"use strict";w();var U2="Function.prototype.bind called on incompatible ",N2=Object.prototype.toString,L2=Math.max,F2="[object Function]",z0=function(e,r){for(var n=[],i=0;i<e.length;i+=1)n[i]=e[i];for(var a=0;a<r.length;a+=1)n[a+e.length]=r[a];return n},j2=function(e,r){for(var n=[],i=r||0,a=0;i<e.length;i+=1,a+=1)n[a]=e[i];return n},H2=function(t,e){for(var r="",n=0;n<t.length;n+=1)r+=t[n],n+1<t.length&&(r+=e);return r};G0.exports=function(e){var r=this;if(typeof r!="function"||N2.apply(r)!==F2)throw new TypeError(U2+r);for(var n=j2(arguments,1),i,a=function(){if(this instanceof i){var A=r.apply(this,z0(n,arguments));return Object(A)===A?A:this}return r.apply(e,z0(n,arguments))},f=L2(0,r.length-n.length),v=[],m=0;m<f;m++)v[m]="$"+m;if(i=Function("binder","return function ("+H2(v,",")+"){ return binder.apply(this,arguments); }")(a),r.prototype){var E=function(){};E.prototype=r.prototype,i.prototype=new E,E.prototype=null}return i}});var zi=R((Z7,$0)=>{"use strict";w();var K2=V0();$0.exports=Function.prototype.bind||K2});var ao=R((X7,Z0)=>{"use strict";w();Z0.exports=Function.prototype.call});var oo=R((Q7,Y0)=>{"use strict";w();Y0.exports=Function.prototype.apply});var J0=R((tA,X0)=>{"use strict";w();X0.exports=typeof Reflect<"u"&&Reflect&&Reflect.apply});var Es=R((iA,Q0)=>{"use strict";w();var W2=zi(),z2=oo(),G2=ao(),V2=J0();Q0.exports=V2||W2.call(G2,z2)});var fo=R((aA,ec)=>{"use strict";w();var $2=zi(),Z2=hi(),Y2=ao(),X2=Es();ec.exports=function(e){if(e.length<1||typeof e[0]!="function")throw new Z2("a function is required");return X2($2,Y2,e)}});var oc=R((fA,ac)=>{"use strict";w();var J2=fo(),tc=li(),ic;try{ic=[].__proto__===Array.prototype}catch(t){if(!t||typeof t!="object"||!("code"in t)||t.code!=="ERR_PROTO_ACCESS")throw t}var Ss=!!ic&&tc&&tc(Object.prototype,"__proto__"),nc=Object,rc=nc.getPrototypeOf;ac.exports=Ss&&typeof Ss.get=="function"?J2([Ss.get]):typeof rc=="function"?function(e){return rc(e==null?e:nc(e))}:!1});var so=R((uA,hc)=>{"use strict";w();var fc=xs(),sc=Ms(),uc=oc();hc.exports=fc?function(e){return fc(e)}:sc?function(e){if(!e||typeof e!="object"&&typeof e!="function")throw new TypeError("getProto: not an object");return sc(e)}:uc?function(e){return uc(e)}:null});var Bs=R((lA,lc)=>{"use strict";w();var Q2=Function.prototype.call,ew=Object.prototype.hasOwnProperty,tw=zi();lc.exports=tw.call(Q2,ew)});var qs=R((dA,gc)=>{"use strict";w();var Oe,rw=ws(),iw=u0(),nw=l0(),aw=d0(),ow=v0(),Zi=_s(),$i=hi(),fw=b0(),sw=_0(),uw=M0(),hw=S0(),lw=A0(),cw=q0(),dw=k0(),pw=P0(),vc=Function,As=function(t){try{return vc('"use strict"; return ('+t+").constructor;")()}catch{}},Xn=li(),vw=Yn(),Rs=function(){throw new $i},yw=Xn?(function(){try{return arguments.callee,Rs}catch{try{return Xn(arguments,"callee").get}catch{return Rs}}})():Rs,Gi=H0()(),it=so(),gw=Ms(),mw=xs(),yc=oo(),Jn=ao(),Vi={},bw=typeof Uint8Array>"u"||!it?Oe:it(Uint8Array),ci={__proto__:null,"%AggregateError%":typeof AggregateError>"u"?Oe:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?Oe:ArrayBuffer,"%ArrayIteratorPrototype%":Gi&&it?it([][Symbol.iterator]()):Oe,"%AsyncFromSyncIteratorPrototype%":Oe,"%AsyncFunction%":Vi,"%AsyncGenerator%":Vi,"%AsyncGeneratorFunction%":Vi,"%AsyncIteratorPrototype%":Vi,"%Atomics%":typeof Atomics>"u"?Oe:Atomics,"%BigInt%":typeof BigInt>"u"?Oe:BigInt,"%BigInt64Array%":typeof BigInt64Array>"u"?Oe:BigInt64Array,"%BigUint64Array%":typeof BigUint64Array>"u"?Oe:BigUint64Array,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?Oe:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":iw,"%eval%":eval,"%EvalError%":nw,"%Float16Array%":typeof Float16Array>"u"?Oe:Float16Array,"%Float32Array%":typeof Float32Array>"u"?Oe:Float32Array,"%Float64Array%":typeof Float64Array>"u"?Oe:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?Oe:FinalizationRegistry,"%Function%":vc,"%GeneratorFunction%":Vi,"%Int8Array%":typeof Int8Array>"u"?Oe:Int8Array,"%Int16Array%":typeof Int16Array>"u"?Oe:Int16Array,"%Int32Array%":typeof Int32Array>"u"?Oe:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":Gi&&it?it(it([][Symbol.iterator]())):Oe,"%JSON%":typeof JSON=="object"?JSON:Oe,"%Map%":typeof Map>"u"?Oe:Map,"%MapIteratorPrototype%":typeof Map>"u"||!Gi||!it?Oe:it(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":rw,"%Object.getOwnPropertyDescriptor%":Xn,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?Oe:Promise,"%Proxy%":typeof Proxy>"u"?Oe:Proxy,"%RangeError%":aw,"%ReferenceError%":ow,"%Reflect%":typeof Reflect>"u"?Oe:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?Oe:Set,"%SetIteratorPrototype%":typeof Set>"u"||!Gi||!it?Oe:it(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?Oe:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":Gi&&it?it(""[Symbol.iterator]()):Oe,"%Symbol%":Gi?Symbol:Oe,"%SyntaxError%":Zi,"%ThrowTypeError%":yw,"%TypedArray%":bw,"%TypeError%":$i,"%Uint8Array%":typeof Uint8Array>"u"?Oe:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?Oe:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?Oe:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?Oe:Uint32Array,"%URIError%":fw,"%WeakMap%":typeof WeakMap>"u"?Oe:WeakMap,"%WeakRef%":typeof WeakRef>"u"?Oe:WeakRef,"%WeakSet%":typeof WeakSet>"u"?Oe:WeakSet,"%Function.prototype.call%":Jn,"%Function.prototype.apply%":yc,"%Object.defineProperty%":vw,"%Object.getPrototypeOf%":gw,"%Math.abs%":sw,"%Math.floor%":uw,"%Math.max%":hw,"%Math.min%":lw,"%Math.pow%":cw,"%Math.round%":dw,"%Math.sign%":pw,"%Reflect.getPrototypeOf%":mw};if(it)try{null.error}catch(t){cc=it(it(t)),ci["%Error.prototype%"]=cc}var cc,ww=function t(e){var r;if(e==="%AsyncFunction%")r=As("async function () {}");else if(e==="%GeneratorFunction%")r=As("function* () {}");else if(e==="%AsyncGeneratorFunction%")r=As("async function* () {}");else if(e==="%AsyncGenerator%"){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(e==="%AsyncIteratorPrototype%"){var i=t("%AsyncGenerator%");i&&it&&(r=it(i.prototype))}return ci[e]=r,r},dc={__proto__:null,"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},Qn=zi(),uo=Bs(),_w=Qn.call(Jn,Array.prototype.concat),xw=Qn.call(yc,Array.prototype.splice),pc=Qn.call(Jn,String.prototype.replace),ho=Qn.call(Jn,String.prototype.slice),Mw=Qn.call(Jn,RegExp.prototype.exec),Ew=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,Sw=/\\(\\)?/g,Bw=function(e){var r=ho(e,0,1),n=ho(e,-1);if(r==="%"&&n!=="%")throw new Zi("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new Zi("invalid intrinsic syntax, expected opening `%`");var i=[];return pc(e,Ew,function(a,f,v,m){i[i.length]=v?pc(m,Sw,"$1"):f||a}),i},Aw=function(e,r){var n=e,i;if(uo(dc,n)&&(i=dc[n],n="%"+i[0]+"%"),uo(ci,n)){var a=ci[n];if(a===Vi&&(a=ww(n)),typeof a>"u"&&!r)throw new $i("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:i,name:n,value:a}}throw new Zi("intrinsic "+e+" does not exist!")};gc.exports=function(e,r){if(typeof e!="string"||e.length===0)throw new $i("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new $i('"allowMissing" argument must be a boolean');if(Mw(/^%?[^%]*%?$/,e)===null)throw new Zi("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=Bw(e),i=n.length>0?n[0]:"",a=Aw("%"+i+"%",r),f=a.name,v=a.value,m=!1,E=a.alias;E&&(i=E[0],xw(n,_w([0,1],E)));for(var A=1,q=!0;A<n.length;A+=1){var I=n[A],C=ho(I,0,1),j=ho(I,-1);if((C==='"'||C==="'"||C==="`"||j==='"'||j==="'"||j==="`")&&C!==j)throw new Zi("property names with quotes must have matching quotes");if((I==="constructor"||!q)&&(m=!0),i+="."+I,f="%"+i+"%",uo(ci,f))v=ci[f];else if(v!=null){if(!(I in v)){if(!r)throw new $i("base intrinsic for "+e+" exists, but the property is not available.");return}if(Xn&&A+1>=n.length){var V=Xn(v,I);q=!!V,q&&"get"in V&&!("originalValue"in V.get)?v=V.get:v=v[I]}else q=uo(v,I),v=v[I];q&&!m&&(ci[f]=v)}}return v}});var di=R((vA,wc)=>{"use strict";w();var mc=qs(),bc=fo(),Rw=bc([mc("%String.prototype.indexOf%")]);wc.exports=function(e,r){var n=mc(e,!!r);return typeof n=="function"&&Rw(e,".prototype.")>-1?bc([n]):n}});var Mc=R((gA,xc)=>{"use strict";w();var qw=Zn()(),Iw=di(),Is=Iw("Object.prototype.toString"),lo=function(e){return qw&&e&&typeof e=="object"&&Symbol.toStringTag in e?!1:Is(e)==="[object Arguments]"},_c=function(e){return lo(e)?!0:e!==null&&typeof e=="object"&&"length"in e&&typeof e.length=="number"&&e.length>=0&&Is(e)!=="[object Array]"&&"callee"in e&&Is(e.callee)==="[object Function]"},kw=(function(){return lo(arguments)})();lo.isLegacyArguments=_c;xc.exports=kw?lo:_c});var qc=R((bA,Rc)=>{"use strict";w();var Ec=di(),Tw=Zn()(),Cw=Bs(),Ow=li(),Cs;Tw?(Sc=Ec("RegExp.prototype.exec"),ks={},co=function(){throw ks},Ts={toString:co,valueOf:co},typeof Symbol.toPrimitive=="symbol"&&(Ts[Symbol.toPrimitive]=co),Cs=function(e){if(!e||typeof e!="object")return!1;var r=Ow(e,"lastIndex"),n=r&&Cw(r,"value");if(!n)return!1;try{Sc(e,Ts)}catch(i){return i===ks}}):(Bc=Ec("Object.prototype.toString"),Ac="[object RegExp]",Cs=function(e){return!e||typeof e!="object"&&typeof e!="function"?!1:Bc(e)===Ac});var Sc,ks,co,Ts,Bc,Ac;Rc.exports=Cs});var kc=R((_A,Ic)=>{"use strict";w();var Pw=di(),Dw=qc(),Uw=Pw("RegExp.prototype.exec"),Nw=hi();Ic.exports=function(e){if(!Dw(e))throw new Nw("`regex` must be a RegExp");return function(n){return Uw(e,n)!==null}}});var Cc=R((MA,Tc)=>{"use strict";w();var Lw=function*(){}.constructor;Tc.exports=()=>Lw});var Uc=R((SA,Dc)=>{"use strict";w();var Pc=di(),Fw=kc(),jw=Fw(/^\s*(?:function)?\*/),Hw=Zn()(),Oc=so(),Kw=Pc("Object.prototype.toString"),Ww=Pc("Function.prototype.toString"),zw=Cc();Dc.exports=function(e){if(typeof e!="function")return!1;if(jw(Ww(e)))return!0;if(!Hw){var r=Kw(e);return r==="[object GeneratorFunction]"}if(!Oc)return!1;var n=zw();return n&&Oc(e)===n.prototype}});var jc=R((AA,Fc)=>{"use strict";w();var Lc=Function.prototype.toString,Yi=typeof Reflect=="object"&&Reflect!==null&&Reflect.apply,Ps,po;if(typeof Yi=="function"&&typeof Object.defineProperty=="function")try{Ps=Object.defineProperty({},"length",{get:function(){throw po}}),po={},Yi(function(){throw 42},null,Ps)}catch(t){t!==po&&(Yi=null)}else Yi=null;var Gw=/^\s*class\b/,Ds=function(e){try{var r=Lc.call(e);return Gw.test(r)}catch{return!1}},Os=function(e){try{return Ds(e)?!1:(Lc.call(e),!0)}catch{return!1}},vo=Object.prototype.toString,Vw="[object Object]",$w="[object Function]",Zw="[object GeneratorFunction]",Yw="[object HTMLAllCollection]",Xw="[object HTML document.all class]",Jw="[object HTMLCollection]",Qw=typeof Symbol=="function"&&!!Symbol.toStringTag,e_=!(0 in[,]),Us=function(){return!1};typeof document=="object"&&(Nc=document.all,vo.call(Nc)===vo.call(document.all)&&(Us=function(e){if((e_||!e)&&(typeof e>"u"||typeof e=="object"))try{var r=vo.call(e);return(r===Yw||r===Xw||r===Jw||r===Vw)&&e("")==null}catch{}return!1}));var Nc;Fc.exports=Yi?function(e){if(Us(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;try{Yi(e,null,Ps)}catch(r){if(r!==po)return!1}return!Ds(e)&&Os(e)}:function(e){if(Us(e))return!0;if(!e||typeof e!="function"&&typeof e!="object")return!1;if(Qw)return Os(e);if(Ds(e))return!1;var r=vo.call(e);return r!==$w&&r!==Zw&&!/^\[object HTML/.test(r)?!1:Os(e)}});var Wc=R((qA,Kc)=>{"use strict";w();var t_=jc(),r_=Object.prototype.toString,Hc=Object.prototype.hasOwnProperty,i_=function(e,r,n){for(var i=0,a=e.length;i<a;i++)Hc.call(e,i)&&(n==null?r(e[i],i,e):r.call(n,e[i],i,e))},n_=function(e,r,n){for(var i=0,a=e.length;i<a;i++)n==null?r(e.charAt(i),i,e):r.call(n,e.charAt(i),i,e)},a_=function(e,r,n){for(var i in e)Hc.call(e,i)&&(n==null?r(e[i],i,e):r.call(n,e[i],i,e))};function o_(t){return r_.call(t)==="[object Array]"}Kc.exports=function(e,r,n){if(!t_(r))throw new TypeError("iterator must be a function");var i;arguments.length>=3&&(i=n),o_(e)?i_(e,r,i):typeof e=="string"?n_(e,r,i):a_(e,r,i)}});var Gc=R((kA,zc)=>{"use strict";w();zc.exports=["Float16Array","Float32Array","Float64Array","Int8Array","Int16Array","Int32Array","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","BigInt64Array","BigUint64Array"]});var $c=R((CA,Vc)=>{"use strict";w();var Ns=Gc(),f_=globalThis;Vc.exports=function(){for(var e=[],r=0;r<Ns.length;r++)typeof f_[Ns[r]]=="function"&&(e[e.length]=Ns[r]);return e}});var Jc=R((PA,Xc)=>{"use strict";w();var Zc=Yn(),s_=_s(),Xi=hi(),Yc=li();Xc.exports=function(e,r,n){if(!e||typeof e!="object"&&typeof e!="function")throw new Xi("`obj` must be an object or a function`");if(typeof r!="string"&&typeof r!="symbol")throw new Xi("`property` must be a string or a symbol`");if(arguments.length>3&&typeof arguments[3]!="boolean"&&arguments[3]!==null)throw new Xi("`nonEnumerable`, if provided, must be a boolean or null");if(arguments.length>4&&typeof arguments[4]!="boolean"&&arguments[4]!==null)throw new Xi("`nonWritable`, if provided, must be a boolean or null");if(arguments.length>5&&typeof arguments[5]!="boolean"&&arguments[5]!==null)throw new Xi("`nonConfigurable`, if provided, must be a boolean or null");if(arguments.length>6&&typeof arguments[6]!="boolean")throw new Xi("`loose`, if provided, must be a boolean");var i=arguments.length>3?arguments[3]:null,a=arguments.length>4?arguments[4]:null,f=arguments.length>5?arguments[5]:null,v=arguments.length>6?arguments[6]:!1,m=!!Yc&&Yc(e,r);if(Zc)Zc(e,r,{configurable:f===null&&m?m.configurable:!f,enumerable:i===null&&m?m.enumerable:!i,value:n,writable:a===null&&m?m.writable:!a});else if(v||!i&&!a&&!f)e[r]=n;else throw new s_("This environment does not support defining a property as non-configurable, non-writable, or non-enumerable.")}});var td=R((UA,ed)=>{"use strict";w();var Ls=Yn(),Qc=function(){return!!Ls};Qc.hasArrayLengthDefineBug=function(){if(!Ls)return null;try{return Ls([],"length",{value:1}).length!==1}catch{return!0}};ed.exports=Qc});var od=R((LA,ad)=>{"use strict";w();var u_=qs(),rd=Jc(),h_=td()(),id=li(),nd=hi(),l_=u_("%Math.floor%");ad.exports=function(e,r){if(typeof e!="function")throw new nd("`fn` is not a function");if(typeof r!="number"||r<0||r>4294967295||l_(r)!==r)throw new nd("`length` must be a positive 32-bit integer");var n=arguments.length>2&&!!arguments[2],i=!0,a=!0;if("length"in e&&id){var f=id(e,"length");f&&!f.configurable&&(i=!1),f&&!f.writable&&(a=!1)}return(i||a||!n)&&(h_?rd(e,"length",r,!0,!0):rd(e,"length",r)),e}});var sd=R((jA,fd)=>{"use strict";w();var c_=zi(),d_=oo(),p_=Es();fd.exports=function(){return p_(c_,d_,arguments)}});var ld=R((KA,yo)=>{"use strict";w();var v_=od(),ud=Yn(),y_=fo(),hd=sd();yo.exports=function(e){var r=y_(arguments),n=1+e.length-(arguments.length-1);return v_(r,n>0?n:0,!0)};ud?ud(yo.exports,"apply",{value:hd}):yo.exports.apply=hd});var Ks=R((zA,vd)=>{"use strict";w();var bo=Wc(),g_=$c(),cd=ld(),js=di(),mo=li(),go=so(),m_=js("Object.prototype.toString"),pd=Zn()(),dd=globalThis,Fs=g_(),Hs=js("String.prototype.slice"),b_=js("Array.prototype.indexOf",!0)||function(e,r){for(var n=0;n<e.length;n+=1)if(e[n]===r)return n;return-1},wo={__proto__:null};pd&&mo&&go?bo(Fs,function(t){var e=new dd[t];if(Symbol.toStringTag in e&&go){var r=go(e),n=mo(r,Symbol.toStringTag);if(!n&&r){var i=go(r);n=mo(i,Symbol.toStringTag)}if(n&&n.get){var a=cd(n.get);wo["$"+t]=a}}}):bo(Fs,function(t){var e=new dd[t],r=e.slice||e.set;if(r){var n=cd(r);wo["$"+t]=n}});var w_=function(e){var r=!1;return bo(wo,function(n,i){if(!r)try{"$"+n(e)===i&&(r=Hs(i,1))}catch{}}),r},__=function(e){var r=!1;return bo(wo,function(n,i){if(!r)try{n(e),r=Hs(i,1)}catch{}}),r};vd.exports=function(e){if(!e||typeof e!="object")return!1;if(!pd){var r=Hs(m_(e),8,-1);return b_(Fs,r)>-1?r:r!=="Object"?!1:__(e)}return mo?w_(e):null}});var Ws=R((VA,yd)=>{"use strict";w();var x_=Ks();yd.exports=function(e){return!!x_(e)}});var Id=R(Pe=>{"use strict";w();var M_=Mc(),E_=Uc(),kt=Ks(),gd=Ws();function Ji(t){return t.call.bind(t)}var md=typeof BigInt<"u",bd=typeof Symbol<"u",_t=Ji(Object.prototype.toString),S_=Ji(Number.prototype.valueOf),B_=Ji(String.prototype.valueOf),A_=Ji(Boolean.prototype.valueOf);md&&(wd=Ji(BigInt.prototype.valueOf));var wd;bd&&(_d=Ji(Symbol.prototype.valueOf));var _d;function ta(t,e){if(typeof t!="object")return!1;try{return e(t),!0}catch{return!1}}Pe.isArgumentsObject=M_;Pe.isGeneratorFunction=E_;Pe.isTypedArray=gd;function R_(t){return typeof Promise<"u"&&t instanceof Promise||t!==null&&typeof t=="object"&&typeof t.then=="function"&&typeof t.catch=="function"}Pe.isPromise=R_;function q_(t){return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?ArrayBuffer.isView(t):gd(t)||Md(t)}Pe.isArrayBufferView=q_;function I_(t){return kt(t)==="Uint8Array"}Pe.isUint8Array=I_;function k_(t){return kt(t)==="Uint8ClampedArray"}Pe.isUint8ClampedArray=k_;function T_(t){return kt(t)==="Uint16Array"}Pe.isUint16Array=T_;function C_(t){return kt(t)==="Uint32Array"}Pe.isUint32Array=C_;function O_(t){return kt(t)==="Int8Array"}Pe.isInt8Array=O_;function P_(t){return kt(t)==="Int16Array"}Pe.isInt16Array=P_;function D_(t){return kt(t)==="Int32Array"}Pe.isInt32Array=D_;function U_(t){return kt(t)==="Float32Array"}Pe.isFloat32Array=U_;function N_(t){return kt(t)==="Float64Array"}Pe.isFloat64Array=N_;function L_(t){return kt(t)==="BigInt64Array"}Pe.isBigInt64Array=L_;function F_(t){return kt(t)==="BigUint64Array"}Pe.isBigUint64Array=F_;function _o(t){return _t(t)==="[object Map]"}_o.working=typeof Map<"u"&&_o(new Map);function j_(t){return typeof Map>"u"?!1:_o.working?_o(t):t instanceof Map}Pe.isMap=j_;function xo(t){return _t(t)==="[object Set]"}xo.working=typeof Set<"u"&&xo(new Set);function H_(t){return typeof Set>"u"?!1:xo.working?xo(t):t instanceof Set}Pe.isSet=H_;function Mo(t){return _t(t)==="[object WeakMap]"}Mo.working=typeof WeakMap<"u"&&Mo(new WeakMap);function K_(t){return typeof WeakMap>"u"?!1:Mo.working?Mo(t):t instanceof WeakMap}Pe.isWeakMap=K_;function Gs(t){return _t(t)==="[object WeakSet]"}Gs.working=typeof WeakSet<"u"&&Gs(new WeakSet);function W_(t){return Gs(t)}Pe.isWeakSet=W_;function Eo(t){return _t(t)==="[object ArrayBuffer]"}Eo.working=typeof ArrayBuffer<"u"&&Eo(new ArrayBuffer);function xd(t){return typeof ArrayBuffer>"u"?!1:Eo.working?Eo(t):t instanceof ArrayBuffer}Pe.isArrayBuffer=xd;function So(t){return _t(t)==="[object DataView]"}So.working=typeof ArrayBuffer<"u"&&typeof DataView<"u"&&So(new DataView(new ArrayBuffer(1),0,1));function Md(t){return typeof DataView>"u"?!1:So.working?So(t):t instanceof DataView}Pe.isDataView=Md;var zs=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:void 0;function ea(t){return _t(t)==="[object SharedArrayBuffer]"}function Ed(t){return typeof zs>"u"?!1:(typeof ea.working>"u"&&(ea.working=ea(new zs)),ea.working?ea(t):t instanceof zs)}Pe.isSharedArrayBuffer=Ed;function z_(t){return _t(t)==="[object AsyncFunction]"}Pe.isAsyncFunction=z_;function G_(t){return _t(t)==="[object Map Iterator]"}Pe.isMapIterator=G_;function V_(t){return _t(t)==="[object Set Iterator]"}Pe.isSetIterator=V_;function $_(t){return _t(t)==="[object Generator]"}Pe.isGeneratorObject=$_;function Z_(t){return _t(t)==="[object WebAssembly.Module]"}Pe.isWebAssemblyCompiledModule=Z_;function Sd(t){return ta(t,S_)}Pe.isNumberObject=Sd;function Bd(t){return ta(t,B_)}Pe.isStringObject=Bd;function Ad(t){return ta(t,A_)}Pe.isBooleanObject=Ad;function Rd(t){return md&&ta(t,wd)}Pe.isBigIntObject=Rd;function qd(t){return bd&&ta(t,_d)}Pe.isSymbolObject=qd;function Y_(t){return Sd(t)||Bd(t)||Ad(t)||Rd(t)||qd(t)}Pe.isBoxedPrimitive=Y_;function X_(t){return typeof Uint8Array<"u"&&(xd(t)||Ed(t))}Pe.isAnyArrayBuffer=X_;["isProxy","isExternal","isModuleNamespaceObject"].forEach(function(t){Object.defineProperty(Pe,t,{enumerable:!1,value:function(){throw new Error(t+" is not supported in userland")}})})});var Td=R((XA,kd)=>{w();kd.exports=function(e){return e&&typeof e=="object"&&typeof e.copy=="function"&&typeof e.fill=="function"&&typeof e.readUInt8=="function"}});var na=R(De=>{w();var Cd=Object.getOwnPropertyDescriptors||function(e){for(var r=Object.keys(e),n={},i=0;i<r.length;i++)n[r[i]]=Object.getOwnPropertyDescriptor(e,r[i]);return n},J_=/%[sdj%]/g;De.format=function(t){if(!To(t)){for(var e=[],r=0;r<arguments.length;r++)e.push(kr(arguments[r]));return e.join(" ")}for(var r=1,n=arguments,i=n.length,a=String(t).replace(J_,function(v){if(v==="%%")return"%";if(r>=i)return v;switch(v){case"%s":return String(n[r++]);case"%d":return Number(n[r++]);case"%j":try{return JSON.stringify(n[r++])}catch{return"[Circular]"}default:return v}}),f=n[r];r<i;f=n[++r])ko(f)||!Qi(f)?a+=" "+f:a+=" "+kr(f);return a};De.deprecate=function(t,e){if(typeof S.default<"u"&&S.default.noDeprecation===!0)return t;if(typeof S.default>"u")return function(){return De.deprecate(t,e).apply(this,arguments)};var r=!1;function n(){if(!r){if(S.default.throwDeprecation)throw new Error(e);S.default.traceDeprecation?console.trace(e):console.error(e),r=!0}return t.apply(this,arguments)}return n};var Bo={},Od=/^$/;S.default.env.NODE_DEBUG&&(Ao=S.default.env.NODE_DEBUG,Ao=Ao.replace(/[|\\{}()[\]^$+?.]/g,"\\$&").replace(/\*/g,".*").replace(/,/g,"$|^").toUpperCase(),Od=new RegExp("^"+Ao+"$","i"));var Ao;De.debuglog=function(t){if(t=t.toUpperCase(),!Bo[t])if(Od.test(t)){var e=S.default.pid;Bo[t]=function(){var r=De.format.apply(De,arguments);console.error("%s %d: %s",t,e,r)}}else Bo[t]=function(){};return Bo[t]};function kr(t,e){var r={seen:[],stylize:ex};return arguments.length>=3&&(r.depth=arguments[2]),arguments.length>=4&&(r.colors=arguments[3]),Ys(e)?r.showHidden=e:e&&De._extend(r,e),vi(r.showHidden)&&(r.showHidden=!1),vi(r.depth)&&(r.depth=2),vi(r.colors)&&(r.colors=!1),vi(r.customInspect)&&(r.customInspect=!0),r.colors&&(r.stylize=Q_),qo(r,t,r.depth)}De.inspect=kr;kr.colors={bold:[1,22],italic:[3,23],underline:[4,24],inverse:[7,27],white:[37,39],grey:[90,39],black:[30,39],blue:[34,39],cyan:[36,39],green:[32,39],magenta:[35,39],red:[31,39],yellow:[33,39]};kr.styles={special:"cyan",number:"yellow",boolean:"yellow",undefined:"grey",null:"bold",string:"green",date:"magenta",regexp:"red"};function Q_(t,e){var r=kr.styles[e];return r?"\x1B["+kr.colors[r][0]+"m"+t+"\x1B["+kr.colors[r][1]+"m":t}function ex(t,e){return t}function tx(t){var e={};return t.forEach(function(r,n){e[r]=!0}),e}function qo(t,e,r){if(t.customInspect&&e&&Ro(e.inspect)&&e.inspect!==De.inspect&&!(e.constructor&&e.constructor.prototype===e)){var n=e.inspect(r,t);return To(n)||(n=qo(t,n,r)),n}var i=rx(t,e);if(i)return i;var a=Object.keys(e),f=tx(a);if(t.showHidden&&(a=Object.getOwnPropertyNames(e)),ia(e)&&(a.indexOf("message")>=0||a.indexOf("description")>=0))return Vs(e);if(a.length===0){if(Ro(e)){var v=e.name?": "+e.name:"";return t.stylize("[Function"+v+"]","special")}if(ra(e))return t.stylize(RegExp.prototype.toString.call(e),"regexp");if(Io(e))return t.stylize(Date.prototype.toString.call(e),"date");if(ia(e))return Vs(e)}var m="",E=!1,A=["{","}"];if(Pd(e)&&(E=!0,A=["[","]"]),Ro(e)){var q=e.name?": "+e.name:"";m=" [Function"+q+"]"}if(ra(e)&&(m=" "+RegExp.prototype.toString.call(e)),Io(e)&&(m=" "+Date.prototype.toUTCString.call(e)),ia(e)&&(m=" "+Vs(e)),a.length===0&&(!E||e.length==0))return A[0]+m+A[1];if(r<0)return ra(e)?t.stylize(RegExp.prototype.toString.call(e),"regexp"):t.stylize("[Object]","special");t.seen.push(e);var I;return E?I=ix(t,e,r,f,a):I=a.map(function(C){return Zs(t,e,r,f,C,E)}),t.seen.pop(),nx(I,m,A)}function rx(t,e){if(vi(e))return t.stylize("undefined","undefined");if(To(e)){var r="'"+JSON.stringify(e).replace(/^"|"$/g,"").replace(/'/g,"\\'").replace(/\\"/g,'"')+"'";return t.stylize(r,"string")}if(Dd(e))return t.stylize(""+e,"number");if(Ys(e))return t.stylize(""+e,"boolean");if(ko(e))return t.stylize("null","null")}function Vs(t){return"["+Error.prototype.toString.call(t)+"]"}function ix(t,e,r,n,i){for(var a=[],f=0,v=e.length;f<v;++f)Ud(e,String(f))?a.push(Zs(t,e,r,n,String(f),!0)):a.push("");return i.forEach(function(m){m.match(/^\d+$/)||a.push(Zs(t,e,r,n,m,!0))}),a}function Zs(t,e,r,n,i,a){var f,v,m;if(m=Object.getOwnPropertyDescriptor(e,i)||{value:e[i]},m.get?m.set?v=t.stylize("[Getter/Setter]","special"):v=t.stylize("[Getter]","special"):m.set&&(v=t.stylize("[Setter]","special")),Ud(n,i)||(f="["+i+"]"),v||(t.seen.indexOf(m.value)<0?(ko(r)?v=qo(t,m.value,null):v=qo(t,m.value,r-1),v.indexOf(`
3
3
  `)>-1&&(a?v=v.split(`
4
4
  `).map(function(E){return" "+E}).join(`