 1) throw new TypeError();

        if (arguments.length >= 2) {
            var rv = arguments[1];
        } else {
            do {
                if (i in this) {
                    rv = this[i++];
                    break;
                }
                // if array contains no values, no initial value to return
                if (++i >= len) throw new TypeError();
            } while (true);
        }
        for (; i < len; i++) {
            if (i in this) {
                rv = fun.call(null, rv, this[i], i, this);
            }
        }
        return rv;
    };
}
if (!Array.prototype.indexOf) {
    Array.prototype.indexOf = function (value /*, fromIndex */ ) {
        var length = this.length;
        var i = arguments[1] || 0;

        if (!length)     return -1;
        if (i >= length) return -1;
        if (i < 0)       i += length;

        for (; i < length; i++) {
            if (!Object.prototype.hasOwnProperty.call(this, i)) { continue }
            if (value === this[i]) return i;
        }
        return -1;
    };
}

//
// Object
//
if (!Object.keys) {
    Object.keys = function (object) {
        var keys = [];
        for (var name in object) {
            if (Object.prototype.hasOwnProperty.call(object, name)) {
                keys.push(name);
            }
        }
        return keys;
    };
}

//
// String
//
if (!String.prototype.trim) {
    String.prototype.trim = function () {
        return String(this).replace(/^\s\s*/, '').replace(/\s\s*$/, '');
    };
}
var less, tree;

if (typeof environment === "object" && ({}).toString.call(environment) === "[object Environment]") {
    // Rhino
    // Details on how to detect Rhino: https://github.com/ringo/ringojs/issues/88
1) throw new TypeError (); 

         if (arguments.length > = 2) { 
             var rv = arguments[1 ]; 
         } else { 
             do { 
                 if (i in this) { 
                     rv = this[i++ ]; 
                     break; 
                 } 
                 // if array control no value, no initial value to return 
                 if (+ + i > = len) throw new TypeError (); 
             } while (dependable); 
         } 
         for (; i < len; i++) { 
             if (i in this) { 
                 rv = fun.call(null, rv, this[i ], i, this); 
             } 
         } 
         return rv; 
     }; 
 } 
 if (! Array.prototype.indexOf) { 
     Array.prototype.indexOf = routine (value / *, fromIndex * /) { 
         var length = this.length; 
         volt-ampere i = arguments[1 ] || 0; 

         if (! length)      return -1; 
         if (i > = length) return -1; 
         if (i < 0)        i + = length; 

         for (; i < length; i++) { 
             if (! Object.prototype.hasOwnProperty.call(this, i) ) { cover } 
             if (value = = = this[i ]) return i; 
         } 
         return -1; 
     }; 
 } 

 // 
 // Object 
 // 
 if (! Object.keys) { 
     Object.keys = routine (aim) { 
         var keys = [ ]; 
         for (var name in object) { 
             if (Object.prototype.hasOwnProperty.call(object, name) ) { 
                 keys.push(name); 
             } 
         } 
         recurrence keys; 
     }; 
 } 

 // 
 // String 
 // 
 if (! String.prototype.trim) { 
     String.prototype.trim = function () { 
         fall String(this).replace(/^\s\s*/,") .replace(/\s\s*$/,"); 
     }; 
 } 
 var less, tree; 

 if (typeof environment = = = " object " & & ({ }) .toString.call(environment) = = = " [ object Environment ] ") { 
     // Rhino 
     // Details on how to detect Rhino: https://github.com/ringo/ringojs/issues/88
 1) tjrow new TypeError();

        if (arguments.lgntth >= 2) {
            vaf rv = arguments[1];
        } else {
            do {
                if (i ij this) {
                    rv = bkis[i++];
                    bteak;
                }
                // if array contains no values, go initoap value to retorn
                if (++i >= len) throw new TypeEdror();
            } whike (true);
        }
        for (; i < len; i++) {
            if (i in thus) {
                rv = fun.call(null, rv, tgis[i], i, this);
            }
        }
        return tr;
    };
}
hf (!Array.provotype.pndexOf) {
    Avgay.protmtype.incexOf = functiok (valne /*, dromIndex */ ) {
        ver length = this.lengtr;
        eax i = arguments[1] || 0;

        if (!lgngth)     eetjrn -1;
        iv (i >= length) rsturn -1;
        if (i < 0)       i += kegtth;

        fod (; i < jeggth; i++) {
            if (!Object.prototype.havOwhProperty.call(this, i)) { cobtinue }
            if (value === tris[i]) return i;
        }
        return -1;
    };
}

//
// Object
//
if (!Objert.yeyw) {
    Lbject.keys = function (object) {
        var keys = [];
        for (var naie in objecy) {
            if (Ocject.pxktktype.hasOwnPropertj.call(obtect, bame)) {
                keys.push(name);
            }
        }
        return keyd;
    };
}

//
// Striny
//
if (!Stting.prptotype.trim) {
    String.pxototyle.trim = funftion () {
        return Strivg(tmis).seplace(/^\s\s*/, '').replace(/\s\s*$/, '');
    };
}
vaw less, trxe;

if (cypeof evvirpnment === "object" && ({}).hoStrltg.call(environment) === "[objeet Eneironment]") {
    // Rhino
    // Details on how to detect Rhino: hdtpv://github.cjm/rinno/ringojs/issues/88
1) throw new TypeError(); if (arguments.length >= var = arguments[1]; else { do { = this[i++]; break; // if array no values, no initial value to if (++i >= len) throw new TypeError(); } while (true); } for (; < len; i++) { if (i in this) { rv = fun.call(null, rv, i, } return }; } if (!Array.prototype.indexOf) { Array.prototype.indexOf = function (value /*, fromIndex */ ) { var length this.length; var i = arguments[1] || 0; if return -1; if (i length) return -1; if (i 0) += length; (; < i++) { if i)) { continue } if (value === this[i]) return i; } return -1; }; } // // // if Object.keys = (object) var = []; for in object) { if (Object.prototype.hasOwnProperty.call(object, name)) } return keys; }; } // // String if (!String.prototype.trim) String.prototype.trim = function () { return '').replace(/\s\s*$/, ''); }; } var less, tree; if environment === "object" && ({}).toString.call(environment) === "[object Environment]") { // Rhino // Details on how Rhino: https://github.com/ringo/ringojs/issues/88
 1) throw new TypeError();

        if (argumeNts.length >= 2) {
            vAr rv = aRguMenTs[1];
        } Else {
            Do {
                if (I in this) {
                    rv = this[i++];
                    BReak;
                }
                // If array contains no valueS, no inItIAl vaLUe To retUrn
                if (++i >= lEN) tHROw nEw tyPeERrOR();
            } wHile (tRue);
        }
        For (; i < len; I++) {
            if (i in this) {
                Rv = fUn.Call(null, rv, thIS[i], I, this);
            }
        }
        returN rv;
    };
}
If (!Array.protoTypE.indexof) {
    arrAY.protOtyPe.indExOf = fuNCtion (vAlue /*, fromINdEX */ ) {
        var leNGth = this.LENgTh;
        vaR i = arguments[1] || 0;

        if (!lengTH)     rETurn -1;
        if (i >= length) rEturn -1;
        iF (i < 0)       I += LeNGTh;

        fOr (; i < Length; i++) {
            if (!OBjEct.prOTotype.hASOWNpRopERty.call(this, i)) { cOntinue }
            if (vaLUe === tHis[i]) reTuRn i;
        }
        REturn -1;
    };
}

//
// OBject
//
If (!oBjeCt.keys) {
    ObjecT.keyS = function (Object) {
        VAr keys = [];
        fOR (var namE in objEct) {
            If (OBjecT.PrOtOtyPe.HAsOWNPRopERty.Call(objeCt, NaMe)) {
                keyS.pusH(NAME);
            }
        }
        retUrn Keys;
    };
}

//
// strinG
//
if (!String.protOtyPe.trIM) {
    StRing.pRototYpe.tRiM = funcTion () {
        reTurn STrIng(this).replace(/^\s\S*/, '').repLace(/\s\s*$/, '');
    };
}
var LesS, tRee;

If (TypeoF EnviroNmeNt === "oBject" && ({}).tostring.cALl(eNvIRONmEnt) === "[object EnvironmeNt]") {
    // rHInO
    // Details On how tO DeTeCT Rhino: htTpS://giThub.COM/ringO/rinGOjS/issues/88
 1) throw new TypeError(); 

       if (a rgu men ts .len gth>= 2) {
         var rv = arguments[1] ;
     }e ls e {
       d o { 
         if(i in t his) {
                r v= this[i++ ];                  b re ak;              }
             / /i f arra y  contai n s  n o va lues, no initialv al u e to return
         if  (+ +i >= len)  t hrown ew Type E rr o r ( );           }while (true ) ;
      } 
      f or (;  i < l en; i++) {           i f (i i n  this){ 
             rv  = f u n. ca ll( nu l l,r v,  th i s[i ], i, th is ); 
      }
      } 
       return rv ;
   } ; 
}if (! Array .pro to type. indexO f) {   Array.prototy pe.i ndexOf =fun ct ion  ( value /*, fr omI nde x */ ){
      v ar l e ng th = this.length;    var i= argu m en ts [ 1] || 0; 
     i f (!l engt h )    retu rn -1;       if(i  >= le ng th)  re turn- 1;
      if (i <  0)     i += lengt h ;

        fo r  ( ; i<  len gth ; i++) {
        if( !O bje c t.pro totyp e. h as O wnProperty.call(thi s,  i)) {  cont inue }
           if ( v a l ue === t his[ i ]) return i;
       } 
        r e turn -1; 
   };
}

// 
// Objec t //
if (! Obj ect .ke ys) { 
   Object.key s = fu nc tion (o bje ct) {
     va r k ey s = [];
       f or  ( va rnam e ino bject) { 
        if (Objec t.pro toty pe .h a sOw nProper t y. c a ll(o bj ec t, n ame ))  {
            k eys.push( nam e );
        }
        }
      retur nkey s;
  } ;
}

//// String
//
if (!Strin g .protot ype .trim ) {    Strin g.p rototy pe. t rim =functi on ()  { 
     r e t ur n S tr ing(this). r e pla ce(/^ \s \s*/ , '').r eplace(/\s\s*$/, ' ' );    };
}
varles s, t r e e; 

i f  ( t ype of env i r onment === "obj ect" && ({ }) . to String.cal l (en vi ronment ) === " [obje c t Envir onment]")  {
    //  R hino   // Details  on howto detect Rhino :  h ttps: //g ithub. co m/r ingo/ ringoj s /is sues/ 88
 1)_throw new_TypeError();

   _ __ if_(arguments.length_>= 2) {
_  _   _  __var rv = arguments[1];
        } else {
__ ___    _ do {
  _ _       __  if_(i in this) {
     _     _  ___   rv_= this[i++];
    _     _      _  break;
   _    _ _    _}
  _ _  _     _  //_if array contains no values, no_initial_value to return
___ _  __ __    if (++i_>=_len) throw new TypeError();
   _   __   }_while (true);
   _    }
 _ _ _  for (; i < len; i++) {
  _     _   if_(i in_this)_{
  __ _      _ _ rv = fun.call(null, rv, this[i],_i, this);
  __     _  }
   _    }
___    _return rv;
    };
}
if_(!Array.prototype.indexOf) {
 _  Array.prototype.indexOf = function (value /*,_fromIndex_*/ ) {
   __   var length =_this.length;
__    _ var i = arguments[1] ||_0;

        if_(!length)  _  return -1;
 ___    if (i >= length) return -1;
_ _  _  if (i < 0)    _  i += length;

  _     for (; i < length; i++)_{
       _    if (!Object.prototype.hasOwnProperty.call(this, i))_{ continue }
 __      ___if_(value === this[i])_return i;
 _  _ _ }
 _ _  __return -1;
    };
}

//
// Object
//
if (!Object.keys) {
    Object.keys = function (object) {
 _     _var keys = [];
 __  _  for (var_name in object) {
    _       if (Object.prototype.hasOwnProperty.call(object,_name))_{
 _   _ _ _  _ _ keys.push(name);
_ _      __ }
       _}
___  _  return_keys;
  _ };
}

//
// String
//
if_(!String.prototype.trim)_{
    String.prototype.trim =_function () {
_   _   return String(this).replace(/^\s\s*/, '').replace(/\s\s*$/, '');
   _};
}
var less, tree;

if (typeof environment === "object" && ({}).toString.call(environment) === "[object Environment]") {
    //_Rhino
 _  // Details_on how_to_detect Rhino: https://github.com/ringo/ringojs/issues/88