This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function x(s, t) { | |
let _map1 = {}; | |
let _map2 = {}; | |
const x1 = Math.floor(Math.random() * (s.length - 1)); | |
const x2 = x1 + Math.floor(Math.random() * (s.length - x1)); | |
let offspring = [Array.from(s), Array.from(t)]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"use strict"; | |
// from http://stackoverflow.com/a/11454049/309483 | |
var combine = function (m, n) { | |
var a = m.length, c = '', count = 0, i; | |
for (i = 0; i < a; i++) { | |
if (m[i] === n[i]) { | |
c += m[i]; | |
} else if (m[i] !== n[i]) { |