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

科技回声

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

GitHubTwitter

首页

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

资源链接

HackerNews API原版 HackerNewsNext.js

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

From Google (Norvig): How to write a spelling check in 20 lines (very cool)

46 点作者 chandrab大约 18 年前

3 条评论

python_kiss大约 18 年前
As one of the collaborative projects on my social network, we asked that people code a spelling check script in PHP. One member, who had zero previous knowledge of PHP took up the challenge. After investing a few hours into it, he came up with the following:<p><a href="http://shuzak.com/Teamwork.php">http://shuzak.com/Teamwork.php</a><p>You're welcome to download the source code. One major issue with the code is that it loses efficiency when the dictionary size is increased from 1,000 to 20,000 words.
评论 #11398 未加载
gms大约 18 年前
The headline is somewhat misrepresentative - this is on Mr. Norvig's personal site, so it's only from him, not from Google.
dhbradshaw大约 18 年前
Half of the value of this example is the chance to see beautiful code. Looking at it has improved my programming.<p>That makes me wonder: are there repositories of quality code out there for us to use as training sets? Links?