TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

A Very Simple Genetic Algorithm Written in Swift 3

105 点作者 brothrock超过 8 年前

5 条评论

LoSboccacc超过 8 年前
&gt; let POP_SIZE = 50<p>c&#x27;mon everyone knows genetic population is 30<p>(I kid I kid but that number has an interesting story <a href="https:&#x2F;&#x2F;statswithcats.wordpress.com&#x2F;2010&#x2F;07&#x2F;11&#x2F;30-samples-standard-suggestion-or-superstition&#x2F;" rel="nofollow">https:&#x2F;&#x2F;statswithcats.wordpress.com&#x2F;2010&#x2F;07&#x2F;11&#x2F;30-samples-st...</a> )
评论 #12932868 未加载
hellofunk超过 8 年前
&gt; Note -- this is much slower than the python version<p>Surprising. Swift, a compiled, static language, is slower than python in this use case?
评论 #12932769 未加载
评论 #12931631 未加载
评论 #12932972 未加载
评论 #12931609 未加载
cfdrake超过 8 年前
Did not expect to see &quot;cfdrake&quot; when I initially clicked the link - nice port! :)<p>Agreed with e28eta - I actually saw RubikSwift demoed at Swift Summit a few days ago as well and enjoyed it. Definitely check it out if you&#x27;re interested in the topic.
e28eta超过 8 年前
I thought this was going to be a link to [1], from a talk given at Swift Summit a couple days ago. I haven&#x27;t really looked at the code for either one to compare them, but for people who are interested, here&#x27;s a second simple genetic algorithm in Swift (found in RubikSwift&#x2F;GeneticsSolver.swift)<p><a href="https:&#x2F;&#x2F;github.com&#x2F;JaviSoto&#x2F;RubikSwift" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;JaviSoto&#x2F;RubikSwift</a>
评论 #12932887 未加载
proyb2超过 8 年前
The other languages are here: <a href="https:&#x2F;&#x2F;github.com&#x2F;jsvazic&#x2F;GAHelloWorld" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;jsvazic&#x2F;GAHelloWorld</a>