Array.Copy=function(c){var b,a=[];for(b=0;b<c.length;b++){a.push(c[b])}return a};Function.prototype.bind=function(){var c=this;var a=Array.Copy(arguments);var b=a.shift();return function(){return c.apply(b,a)}};if(!Array.forEach){Array.prototype.forEach=function(d,e){var c=e||window;for(var b=0,a=this.length;b<a;++b){d.call(c,this[b],b,this)}}}if(!Array.every){Array.prototype.every=function(d,e){var c=e||window;for(var b=0,a=this.length;b<a;++b){if(!d.call(c,this[b],b,this)){return false}}return true}}if(!Array.some){Array.prototype.some=function(d,e){var c=e||window;for(var b=0,a=this.length;b<a;++b){if(d.call(c,this[b],b,this)){return true}}return false}}if(!Array.map){Array.prototype.map=function(f,g){var e=g||window;var b=[];for(var d=0,c=this.length;d<c;++d){b.push(f.call(e,this[d],d,this))}return b}}if(!Array.filter){Array.prototype.filter=function(f,g){var e=g||window;var b=[];for(var d=0,c=this.length;d<c;++d){if(!f.call(e,this[d],d,this)){continue}b.push(this[d])}return b}}if(!Array.indexOf){Array.prototype.indexOf=function(c,d){var d=d||0;for(var b=d,a=this.length;b<a;++b){if(this[b]===c){return b}}return -1}}if(!Array.lastIndexOf){Array.prototype.lastIndexOf=function(b,c){var c=c||this.length;if(c>=this.length){c=this.length}if(c<0){c=this.length+c}for(var a=c;a>=0;--a){if(this[a]===b){return a}}return -1}}if(!Array.splice){Array.prototype.splice=function(d,c){var b,e=new Array();var a=new Array();for(b=0;b<d;b++){e.push(this[b])}for(b=d;b<d+c;b++){a.push(this[b])}if(arguments.length>2){for(b=2;b<arguments.length;b++){e.push(arguments[b])}}for(b=d+c;b<this.length;b++){e.push(this[b])}for(b=0;b<e.length;b++){this[b]=e[b]}this.length=e.length;return a}}if(!Array.remove){Array.prototype.remove=function(a){this.removeAt(this.indexOf(a));return a}}if(!Array.removeAt){Array.prototype.removeAt=function(a){var b=this[a];if(b){this.splice(a,1)}return b}};
