No problem. In addition to the code you had below, you also added the following external JS libraries:

https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.5.2/p5.js

https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.5.2/addons/p5.dom.js

```
var test = [0,1,-2,-3]
var test1= [5,10,15,20]
var test2 = [5,10,15,20]
var tester = [test,test1]
function test12(test){
this.score = Math.random()
}
var testarr = []
for(var i = 0; i < 20; i++){
testarr[i] = new test12();
}
//console.log(matrixCrossover(tester,test1,true,.5))
//console.log(crossover(test,test1,false,0))
function arrMultScalar(input,value) {
//Multiplies every element in an array by a scalar i.e. [5,10]*5 returns [25,50]
var array3 = [];
for(var i = 0; i < input.length; i++){
array3[i] = input[i]*value;
}
return array3;
}
function arrMult(array1,array2){
//Multiplies each number in an array by each number in a different array i.e. [5,10]*[2,5] returns [10,50]
var array3 = []
for(var j = 0; j < array1.length; j++){
array3[j] = array1[j]*array2[j];
}
return array3;
}
function arrAdd(array){
//Adds all elements in an arry i.e. [5,10,15,20] returns = 50
function add(a, b) {
return a + b;
}
return array.reduce(add,0);
}
function arrMultAddSig(array1,array2,bool){
//Multiplies i in array1 by i in array2 then sums up that array, then squashes it to between 0 and 1 with a sigmoid if bool is false does not sigmoid
array3 = arrMult(array1,array2);
array4 = arrAdd(array3);
if(bool){
return sigmoid(array4);
} else{
return array4;
}
}
function sigmoid(t) {
//just a sigmoid function for activation
return 1/(1+Math.pow(Math.E, -t));
}
function matrixMultAddSig(array1,array2,boolean){
//Loops through an array of arrays and performs arrMultAddSig on each of them by the second array
var array10x = []
for(var k = 0; k < array1.length; k++){
array10x[k] = arrMultAddSig(array1[k],array2,boolean);
}
return array10x;
}
function crossover(partner1,partner2,mutatechild,mutationrate){
var mid = Math.floor(Math.random() * (partner1.length - 0)) + 0
var child = [];
for(var i = 0; i < partner1.length; i++){
if(i > mid){
child[i] = partner1[i]
} else
child[i] = partner2[i]
}
if(mutatechild){
mutate(child,mutationrate);
}
return child;
}
function mutate(being,mutationrate){
for(var i = 0; i < being.length; i++){
var chance = Math.random()
if(chance < mutationrate){
being[i] = Math.random();
}
}
}
function orderFromValue(array,ascendOrDescend){
if(ascendOrDescend == 'ASCEND'){
array.sort(function(a, b){return a.score - b.score});
} else if(ascendOrDescend == 'DESCEND'){
array.sort(function(a, b){return b.score - a.score});
}
}
function chanceWheel(array,numberOfSelectants){
}
// function matrixCrossover(parent1,parent2,mutatechild,mutationrate){
// var child = [];
// for(var i = 0; i < parent1.length; i++){
// child[i] = crossover(parent1[i],parent2[i],mutatechild,mutationrate)
// return child
// }
// }
```