September 2017 Update
This commit is contained in:
parent
bba7bfd280
commit
ba8067c3b7
14570 changed files with 153136 additions and 63871 deletions
|
|
@ -3,7 +3,7 @@ constant mutate_chance = .08;
|
|||
constant @alphabet = flat 'A'..'Z',' ';
|
||||
constant C = 100;
|
||||
|
||||
sub mutate { $^string.subst(/./, { rand < mutate_chance ?? @alphabet.pick !! $/ }, :g) }
|
||||
sub mutate { [~] (rand < mutate_chance ?? @alphabet.pick !! $_ for $^string.comb) }
|
||||
sub fitness { [+] $^string.comb Zeq state @ = target.comb }
|
||||
|
||||
loop (
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue