!function(){"use strict";functione(r){returnfunction(e){returnt=typeof(n=e),(null===n?"null":"object"==t&&(Array.prototype.isPrototypeOf(n)||n.constructor&&"Array"===n.constructor.name)?"array":"object"==t&&(String.prototype.isPrototypeOf(n)||n.constructor&&"String"===n.constructor.name)?"string":t)===r;varn,t}}functionn(n){returnfunction(e){returntypeofe===n}}functiont(n){returnfunction(e){returnn===e}}functionl(e){return!(null==e)}functionE(){}functionC(e){returnfunction(){returne}}functionS(e){returne}functionr(e,n){returne===n}varT=e("string"),g=e("object"),a=e("array"),h=t(null),o=n("boolean"),u=t(void0),c=n("function"),f=n("number");functionP(r){for(varo=[],e=1;e<arguments.length;e++)o[e-1]=arguments[e];returnfunction(){for(vare=[],n=0;n<arguments.length;n++)e[n]=arguments[n];vart=o.concat(e);returnr.apply(null,t)}}functionp(n){returnfunction(e){return!n(e)}}functioni(){returns}varv=C(!1),x=C(!0),s={fold:function(e,n){returne()},isSome:v,isNone:x,getOr:S,getOrThunk:m,getOrDie:function(e){thrownewError(e||"error: getOrDie called on none.")},getOrNull:C(null),getOrUndefined:C(void0),or:S,orThunk:m,map:i,each:E,bind:i,exists:v,forall:x,filter:function(){returns},toArray:function(){return[]},toString:C("none()")};functionm(e){returne()}functiony(e,n){return-1<G.call(e,n)}functionR(e,n){for(vart=0,r=e.length;t<r;t++)if(n(e[t],t))return!0;return!1}functionD(e,n){for(vart=[],r=0;r<e;r++)t.push(n(r));returnt}functionO(e,n){for(vart=e.length,r=newArray(t),o=0;o<t;o++){varu=e[o];r[o]=n(u,o)}returnr}functionA(e,n){for(vart=0,r=e.length;t<r;t++)n(e[t],t)}functiond(e,n){for(vart=[],r=[],o=0,u=e.length;o<u;o++){vari=e[o];(n(i,o)?t:r).push(i)}return{pass:t,fail:r}}functionk(e,n){for(vart=[],r=0,o=e.length;r<o;r++){varu=e[r];n(u,r)&&t.push(u)}returnt}functionI(e,r,o){returnfunction(e){for(varn,t=e.length-1;0<=t;t--)n=e[t],o=r(o,n,t)}(e),o}functionB(e,t,r){returnA(e,function(e,n){r=t(r,e,n)}),r}functionw(e,n){returnfunction(e,n,t){for(varr=0,o=e.length;r<o;r++){varu=e[r];if(n(u,r))returnq.some(u);if(t(u,r))break}returnq.none()}(e,n,v)}functionb(e,n){for(vart=0,r=e.length;t<r;t++)if(n(e[t],t))returnq.some(t);returnq.none()}functionM(e){for(varn=[],t=0,r=e.length;t<r;++t){if(!a(e[t]))thrownewError("Arr.flatten item "+t+" was not an array, input: "+e);$.apply(n,e[t])}returnn}functionN(e,n){returnM(O(e,n))}functionz(e,n){for(vart=0,r=e.length;t<r;++t)if(!0!==n(e[t],t))return!1;return!0}functionL(e,n){for(vart={},r=0,o=e.length;r<o;r++){varu=e[r];t[String(u)]=n(u,r)}returnt}function_(e){return[e]}functionW(e,n){return0<=n&&n<e.length?q.some(e[n]):q.none()}functionj(e){returnW(e,0)}functionF(e){returnW(e,e.length-1)}functionH(e,n){for(vart=0;t<e.length;t++){varr=n(e[t],t);if(r.isSome())returnr}returnq.none()}varV=function(t){functione(){returno}functionn(e){returne(t)}varr=C(t),o={fold:function(e,n){returnn(t)},isSome:x,isNone:v,getOr:r,getOrThunk:r,getOrDie:r,getOrNull:r,getOrUndefined:r,or:e,orThunk:e,map:function(e){returnV(e(t))},each:function(e){e(t)},bind:n,exists:n,forall:n,filter:function(e){returne(t)?o:s},toArray:function(){return[t]},toString:function(){return"some("+t+")"}};returno},q={some:V,none:i,from:function(e){returnnull==e?s:V(e)}},U=Array.prototype.slice,G=Array.prototype.indexOf,$=Array.prototype.push,K=function(){return(K=Object.assign||function(e){for(varn,t=1,r=arguments.length;t<r;t++)for(varoinn=arguments[t])Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o]);returne}).apply(this,arguments)};functionX(e,n,t){if(t||2===arguments.length)for(varr,o=0,u=n.length;o<u;o++)!r&&oinn||((r=r||Array.prototype.slice.call(n,0,o))[o]=n[o]);returne.concat(r||Array.prototype.slice.call(n))}functionY(t){varr,o=!1;returnfunction(){for(vare=[],n=0;n<arguments.length;n++)e[n]=arguments[n];returno||(o=!0,r=t.apply(null,e)),r}}functionJ(e,n){vart=String(n).toLowerCase();returnw(e,function(e){returne.search(t)})}functionQ(e,n,t){return""===n||e.length>=n.length&&e.substr(t,t+n.length)===n}functionZ(e,