<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>programming language | 酷 壳 - CoolShell</title>
	<atom:link href="https://coolshell.cn/tag/programming-language/feed" rel="self" type="application/rss+xml" />
	<link>https://coolshell.cn</link>
	<description>享受编程和技术所带来的快乐 - Coding Your Ambition</description>
	<lastBuildDate>Tue, 21 Feb 2012 00:07:24 +0000</lastBuildDate>
	<language>zh-CN</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.2</generator>
	<item>
		<title>千万别惹程序员</title>
		<link>https://coolshell.cn/articles/6639.html</link>
					<comments>https://coolshell.cn/articles/6639.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Mon, 20 Feb 2012 23:54:57 +0000</pubDate>
				<category><![CDATA[编程语言]]></category>
		<category><![CDATA[轶事趣闻]]></category>
		<category><![CDATA[Hack]]></category>
		<category><![CDATA[Programmer]]></category>
		<category><![CDATA[programming language]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[程序员]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=6639</guid>

					<description><![CDATA[<p>酷壳好久没有发娱乐性质的技术文章了，搞得气氛有点严肃了，考虑到程序员们都是比较严肃和容易较真的类书呆子的群体，所以，需要更新一个有娱乐性质的文章了。正好最近看到...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/6639.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/6639.html">千万别惹程序员</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>酷壳好久没有发娱乐性质的技术文章了，搞得气氛有点严肃了，考虑到程序员们都是比较严肃和容易较真的类书呆子的群体，所以，需要更新一个有娱乐性质的文章了。正好最近看到了两个比较有趣的图，在新浪微博上都得到了比较不错的反响，因此，更新到酷壳上来。</p>
<h4>如果编程语言是一种刀</h4>
<p>下面这个图是把编程语言看做是一种刀，那么会是什么样的。这个图我个人感觉很有意思。</p>
<p><img decoding="async" loading="lazy" class="aligncenter size-full wp-image-6642" title="programming language" src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language.jpg" alt="" width="400" height="450" srcset="https://coolshell.cn/wp-content/uploads/2012/02/programming-language.jpg 400w, https://coolshell.cn/wp-content/uploads/2012/02/programming-language-267x300.jpg 267w, https://coolshell.cn/wp-content/uploads/2012/02/programming-language-240x270.jpg 240w" sizes="(max-width: 400px) 100vw, 400px" /></p>
<p>对于这个图，最好不要解释，意会就好。不过，我却有点想不解风情，忍不住想解释一下。</p>
<p><span id="more-6639"></span></p>
<ul>
<li>C++，C，Pascal 都是瑞士军刀，说明是用来做细活的工具。C语言的刀上有个USB，说明是可以做硬件操作的。C++的刀是什么都有，说明C++是一种功能繁多的语言。（图中C++的那把瑞士军刀很强大，不要以为其是虚构的，这把刀是真实存在的，叫Wenger巨人刀，<a href="http://www.wenger.ch/giant-knife-wenger-swiss-army-knife" target="_blank">http://www.wenger.ch/giant-knife-wenger-swiss-army-knife</a> (这个网页上有个Youtube视频，可以爬墙去看)，<a href="http://s.taobao.com/search?q=giant-knife-wenger-swiss-army-knife&amp;keyword=&amp;commend=all&amp;ssid=s5-e&amp;search_type=item&amp;atype=&amp;tracelog=&amp;sourceId=tb.index&amp;initiative_id=tbindexz_20120220" target="_blank">淘宝上有卖的</a>，价格在1万4左右。）</li>
<li>Java/C#是一把塑料餐刀，这说明，Java和C#语言是带虚拟机的，而且其语法和使用并不像C++那么复杂，其泛型编程可以有很多种玩法，而Java和C#的泛型编程是比较单一的。</li>
<li>Python是把电锯，人挡杀人，佛招杀佛，威力很大，面对大型的物体的修整，比C++/C/Java什么的得心应手得多得多，但是对于一些精细的调优工作，明显不行。这和Ruby很像。</li>
<li>PHP没有MySQL，明显是被幽默了一把。不过最近对PHP的批评越来越多，不过，facebook的PHP的引擎HiPo已经很牛B了。</li>
<li>Perl是一本日本武士刀，是忍者玩的语言。</li>
<li>VB，就是一个玩具。你见过用塑料玩具勺当刀的吗？Haskell感觉是外星来的。呵呵</li>
</ul>
<h4>千万别惹程序员</h4>
<p>下图一张昨天我公司内部被传递的图片。经典的SQL注入式攻击。千万别惹程序员</p>
<p><img decoding="async" loading="lazy" class="aligncenter" title="SQL-injection-attack(adjusted)" src="https://coolshell.cn/wp-content/uploads/2012/02/SQL-injection-attackadjusted.jpg" alt="" width="600" height="407" /></p>
<p>这是一个有技术含量的号牌遮挡。我们先不说其是不是能奏效，不过，这个创意相当的NB啊。当你驾车通过某些路口时，被摄像头捕捉到你的车牌，通过OCR变成文本，然后插入数据库，于是，上图的这个车牌就成了SQL注入。（不要以为车牌的OCR技术还不行，这项目技术已经非常成熟了，无论是国内还是国外）。这张图片就如同“<a title="Web开发中需要了解的东西" href="https://coolshell.cn/articles/6043.html" target="_blank">Web开发中应该知道的事</a>”中说的一样——永远不要相信用户的输入。</p>
<p><strong>插曲</strong>：我昨天把这张图片<a href="http://weibo.com/1401880315/y6kIAj1oN" target="_blank">放到微博</a>，结果，<strong>被转了几万次，上了热门转发的top list和一些社会热点和明星八卦排在了一起</strong>。主要是被“<em>@微博搞笑排行榜:  @全球潮流趣闻:  @实用小百科: @经典英文语录:  @当时我就泪奔了: @老榕: @全球经典音乐: @环球汽车搜罗: @怪诞心理行为学: @精彩电影: @互联网的那点事: @潮混搭:  @热门微博: @SinaAppEngine:</em> ” 还有些什么体育记者，法律记者都转了， 这些转发了。这多少让我觉得有些诧异，这是很技术的一件事啊，怎么连什么电影，英文对白，汽车，音乐什么的都转了？我是相当的费解啊，我只能有两个认为——</p>
<ol>
<li>简单的认为关心技术的人还是很多的。</li>
<li>复杂地认为国人是喜欢起哄的，不问为什么。</li>
</ol>
<p>（全文完）<!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" id="wp_rp_first"><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/1992.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2009/12/language-fanboys-150x150.jpg" alt="程序员眼中的编程语言" width="150" height="150" /></a><a href="https://coolshell.cn/articles/1992.html" class="wp_rp_title">程序员眼中的编程语言</a></li><li ><a href="https://coolshell.cn/articles/22298.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2022/10/communication-150x150.png" alt="聊聊团队协同和协同工具" width="150" height="150" /></a><a href="https://coolshell.cn/articles/22298.html" class="wp_rp_title">聊聊团队协同和协同工具</a></li><li ><a href="https://coolshell.cn/articles/22173.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2022/02/http_method-150x150.png" alt="“一把梭：REST API 全用 POST”" width="150" height="150" /></a><a href="https://coolshell.cn/articles/22173.html" class="wp_rp_title">“一把梭：REST API 全用 POST”</a></li><li ><a href="https://coolshell.cn/articles/22157.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2022/02/monitoring-150x150.jpeg" alt="谈谈公司对员工的监控" width="150" height="150" /></a><a href="https://coolshell.cn/articles/22157.html" class="wp_rp_title">谈谈公司对员工的监控</a></li><li ><a href="https://coolshell.cn/articles/21589.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2021/07/knowledge_sharing-300x169-1-150x150.jpeg" alt="如何做一个有质量的技术分享" width="150" height="150" /></a><a href="https://coolshell.cn/articles/21589.html" class="wp_rp_title">如何做一个有质量的技术分享</a></li><li ><a href="https://coolshell.cn/articles/20977.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2020/08/programmer.01-e1596792460687-150x150.png" alt="程序员如何把控自己的职业" width="150" height="150" /></a><a href="https://coolshell.cn/articles/20977.html" class="wp_rp_title">程序员如何把控自己的职业</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/6639.html">千万别惹程序员</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/6639.html/feed</wfw:commentRss>
			<slash:comments>95</slash:comments>
		
		
			</item>
		<item>
		<title>读书笔记：对线程模型的批评</title>
		<link>https://coolshell.cn/articles/4626.html</link>
					<comments>https://coolshell.cn/articles/4626.html#comments</comments>
		
		<dc:creator><![CDATA[Ian.sino]]></dc:creator>
		<pubDate>Tue, 03 May 2011 02:23:27 +0000</pubDate>
				<category><![CDATA[技术读物]]></category>
		<category><![CDATA[操作系统]]></category>
		<category><![CDATA[程序设计]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[Design]]></category>
		<category><![CDATA[Programmer]]></category>
		<category><![CDATA[programming language]]></category>
		<category><![CDATA[threading model]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=4626</guid>

					<description><![CDATA[<p>——感谢Ian.Sian投递本文—— 多线程模型是主流的并发编程模型。在过去几十年来，多线程模型一直是开发并发程序的有力工具。然而，它的历史并非总那么美好。19...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/4626.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/4626.html">读书笔记：对线程模型的批评</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script><span style="color: #cc0000;"><strong>——感谢Ian.Sian投递本文——</strong></span></p>
<p>多线程模型是主流的并发编程模型。在过去几十年来，多线程模型一直是开发并发程序的有力工具。然而，它的历史并非总那么美好。1997年，NASA 的“火星探路者”号在执行任务的途中遭遇了严重的时序异常（参见 &#8220;<a href="http://research.microsoft.com/en-us/um/people/mbj/mars_pathfinder/mars_pathfinder.html" target="_blank">What really happend on Mars</a>&#8220;，注目 follow-up 中的<a href="http://research.microsoft.com/en-us/um/people/mbj/mars_pathfinder/Authoritative_Account.html" target="_blank">现身说法</a>），无法发回探测数据。如果不是 NASA 远程刷新了程序，它的结局就只能是报废在火星上。这一切都是由程序中潜藏的一个优先级反转 bug 造成的。更早的例子还有80年代的一系列 <a title="Therac-25" href="http://en.wikipedia.org/wiki/Therac-25" target="_blank">Therac-25</a> 型医用粒子加速器事故。在这些加速器释放出的过量辐射照射之下，数位病人死亡。事后调查显示，至少有一次发生事故的原因，是加速器的控制软件中，存在一个只能由特定操作序列引发的竞争条件 bug。你也许认为这些只是陈年往事，但是直到现在，即便是世界500强公司们高价买来的信息系统，也同样避免不了这些问题。这导致许多程序员认为线程是个潘多拉魔盒，对它采取能躲就躲的态度。然而近来计算机的发展使得躲猫猫的空间越来越小：随便从市场上淘一个CPU，它里面也有不止一个核心。未来的程序员只会有越来越多的机会接触到并发编程，而无法再独善其身了。</p>
<p>加州大学伯克利分校教授，<a href="http://ptolemy.eecs.berkeley.edu/~eal/" target="_blank">爱德华 A. 李</a>在2006年做了一次题为<a href="http://www.eecs.berkeley.edu/Pubs/TechRpts/2006/EECS-2006-1.html" target="_blank">《线程的麻烦 (The Problem with Threads)》</a>的学术报告。在报告中他提到：看上去，多线程只是对核心语言的小小扩展，甚至可以以第三方库的形式存在。但实质上，多线程程序和原有的核心语言编写的程序已经完全不同了。其原因在于，由于多线程程序可能以任意的次序交错执行，程序再也无法像顺序执行时那样产生确定的结果。多线程程序容易编写(因为写的是顺序程序)，但是难分析，难调试，更容易出错。</p>
<p>在我的想法中，产生问题的根源，是多线程模型作为对并发问题的一个抽象，是很不完善的。<span id="more-4626"></span>抽象的实质是对问题的转换。我们可以把抽象应用于一个问题，把它转换成另一个（或许）更简单的问题来解决。解决了转换后的简单问题，就意味着解决了原有的困难问题。严格来说，一个抽象一定要保存原有问题的结构，同时去除无关细节。但是，由于我们生活的世界并没有什么东西是完全“严格”的，现实中使用的抽象有时会隐藏解决问题的关键细节，或者残留一些不该漏出来的东西。评价一个抽象的好坏，也就不止是看它能节省多少代码，和它的界面有多优美这么简单，同时还要看看在一个问题被抽象转换之后，留了下来的细节还能不能好好地解决它。</p>
<p>我们可以从这个意义上理解为什么线程模型是个很糟糕的抽象。一方面，对解决问题很关键的细节（如执行次序）被隐藏起来并受到了粗暴的对待。另一方面，线程模型极力兼容顺序程序的设计思想也使得如共享变量这样的，与线程不兼容的细节依然残留在程序员们的视线之内。我们无力控制程序的执行次序，而我们程序的正确性却依赖于对共享变量的有序变更。可以说，线程提供给我们的抽象简直是千疮百孔。我们还能用它干活，只是因为我们手里还有加锁机制，而它可以部分地堵上线程模型的漏洞。讽刺的是，引入加锁机制解决问题的同时，又带来了新的问题，所以我们编写多线程程序总会遇上死锁，活锁，优先级反转……等等。</p>
<p>同样作为并发编程问题的抽象，<a href="http://c2.com/cgi/wiki?ActorsModel" target="_blank">角色模型</a>（Actor Model） 比线程模型好就好在，它的资源分享不像线程模型那样通过共享变量来进行。角色模型中的资源分享只能通过特定的机制（消息传递）来进行。你在角色模型里依然可能犯错误，如你可能制造死锁，也有可能造成优先级反转。但是没有共享变量就意味着没有了竞争条件，所以绝大部分资源也用不着上锁了。这样一来，原先至关重要的细节变得不那么重要，问题就这么解决了。</p>
<p>一般来说，在修复一个糟糕的抽象时，可以采取的策略分如下两类：</p>
<ul>
<li>把造成问题的那部分抽象拿掉，直接露出底层的细节</li>
<li>换一个和底层兼容性更好的抽象模型</li>
</ul>
<p>以 <a href="http://en.wikipedia.org/wiki/MapReduce" target="_blank">MapReduce </a>为例，它在解决分布式计算问题时，采取的是第一类策略。与现时流行的做法相反，MapReduce 并不试图制造计算是在单一场所完成的假象(流行话讲叫“云计算”)，相反它需要程序员自己把问题拆分到集群中不同的机器上。同时，它却隐藏了大量其他细节。这种另类策略导致批评 MapReduce “<a href="http://databasecolumn.vertica.com/database-innovation/mapreduce-a-major-step-backwards/" target="_blank">太底层，不通用</a>” 的声音不绝于耳， 然而这正是 MapReduce 聪明的地方。它放弃面面俱到，集中精力于高效地解决一小类问题（这类问题与排序问题有类似的结构），同时对其他的问题故意视而不见。它的流行证明了这一策略的成功。</p>
<p>角色模型，通信进程（<a href="http://en.wikipedia.org/wiki/Communicating_sequential_processes" target="_blank">Communicating Sequential Processes</a>, CSP），以及函数式编程（FP）在应对并发编程问题时不约而同地选择了第二类策略。它们采用了与并发兼容性更好的抽象。角色模型与通信进程从线程模型的问题中抹去了共享变量，纯粹 FP 则抹掉了“变量”的可变性。CSP 还可以降低程序执行次序的不确定性（因为在CSP中执行次序默认是确定的，不确定性必须在程序设计时显式声明）。由于这些努力，这几种模型都避免了落入线程模型的麻烦中，得到了对并发问题的更优美的解法。我们可以说，这些模型提供的抽象比线程模型的都要好。很遗憾的是，它们尽管优美，但却乏人问津。角色模型与通信进程目前不被任何主流操作系统原生支持（微软在 Windows 7 附带的新并行运行时 <a href="http://msdn.microsoft.com/en-us/library/dd504870.aspx" target="_blank">ConcRT </a>中加入了基于角色模型的 Asynchronous Agents Library，使得状况稍微改观了一点）。FP 的年岁几乎和计算机语言的历史一样古老， 但它的市场份额直到现在也小得可怜。</p>
<p>也许一切都是因为线程模型表面上那迷惑人的简单性，以及墨菲定律的变体：布劳尔技术惯性定律（已经成功的技术在新的，更好的技术出现时也会赖着不走）。我们曾经接纳了一个有缺点的解决方案，而现在我们被捆绑在这个方案上了。我们为线程模型写了成百上千万行的代码，而现在这些代码的重量束缚住我们的手脚，使得我们无法前行。</p>
<p>解决线程模型带来的问题的正确做法，是推广新的，更完善的模型。既然解决问题的阻碍同时来自于新技术的低认知度和现有代码的拖累，很自然地有两个方面的工作要做。一、使得新技术更容易被多数程序员使用，二、想办法让现有的代码和新技术兼容。</p>
<p>在兼容老代码这一头，我们已经有了一些行动。微软在 Windows 7 中提供一个称为<a href="http://msdn.microsoft.com/en-us/library/dd627187%28v=vs.85%29.aspx" target="_blank">用户模式调度 </a>(UMS) 的功能。UMS 可以将内核模式的线程转换为用户模式线程，而应用程序可以自己提供一个 UMS 调度器来调度它们。这意味着，我们现在有机会重载掉系统调度器的默认行为，而根据应用自身的特点给出更合理的调度安排来。这个功能可以用在构造更容易使用的并发模型上，这样开发的模型可以与老代码兼容（但 UMS 有一个让人迷惑的限制：只能用在64bit 的Windows 7 版本上）。</p>
<p>同样地，在推广新技术方面，现在也有了很多成果。除了角色模型外，事务性内存(这又是一种避免竞争条件，从而避免加锁的方法)正在研究中；CSP 已经有了数个实现（如由 Kent 大学开发，针对 Java 的 <a href="http://www.cs.kent.ac.uk/projects/ofa/jcsp/" target="_blank">JCSP</a>），同时还有针对 CSP 的模型检证工具；至于 FP，最近因为人们认为 Web 系统的建模可以在函数式编程范式中更好的表达，FP 正在唤起人们的注意。我们缺的只剩下新技术的成功应用范例（实际上，前面的技术并不是没有成功范例，我们缺的是经验能够大规模运用的范例 ），以及一支理解这些技术的程序员大军了。对于这后一条，我甚至想，既然多线程编程唯一&#8221;容易&#8221;的事情是写代码，何不做出一种工具来让程序员们可以用写顺序程序的思维来在这些新模型中编写程序呢？这样的工具会帮助程序员利用线性程序的思维来理解代码，但是同时又让人注意到自己的改动正在影响系统的哪一部分。如果新模型的代码变得好理解了，也许更多的人会使用它们。</p>
<p>（全文完）<!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/18024.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2017/07/api-design-300x278-2-150x150.jpg" alt="API设计原则 &#8211; Qt官网的设计实践总结" width="150" height="150" /></a><a href="https://coolshell.cn/articles/18024.html" class="wp_rp_title">API设计原则 &#8211; Qt官网的设计实践总结</a></li><li ><a href="https://coolshell.cn/articles/17680.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2017/02/gitlab-600-150x150.jpg" alt="从Gitlab误删除数据库想到的" width="150" height="150" /></a><a href="https://coolshell.cn/articles/17680.html" class="wp_rp_title">从Gitlab误删除数据库想到的</a></li><li ><a href="https://coolshell.cn/articles/17459.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2016/08/HighAvailability-BK-150x150.png" alt="关于高可用的系统" width="150" height="150" /></a><a href="https://coolshell.cn/articles/17459.html" class="wp_rp_title">关于高可用的系统</a></li><li ><a href="https://coolshell.cn/articles/9949.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2013/07/inverted-bookshelf_thumb-150x150.jpg" alt="IoC/DIP其实是一种管理思想" width="150" height="150" /></a><a href="https://coolshell.cn/articles/9949.html" class="wp_rp_title">IoC/DIP其实是一种管理思想</a></li><li ><a href="https://coolshell.cn/articles/6775.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/24.jpg" alt="Bret Victor &#8211; Inventing on Principle" width="150" height="150" /></a><a href="https://coolshell.cn/articles/6775.html" class="wp_rp_title">Bret Victor &#8211; Inventing on Principle</a></li><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/4626.html">读书笔记：对线程模型的批评</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/4626.html/feed</wfw:commentRss>
			<slash:comments>37</slash:comments>
		
		
			</item>
		<item>
		<title>编程语言流行度</title>
		<link>https://coolshell.cn/articles/3385.html</link>
					<comments>https://coolshell.cn/articles/3385.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Mon, 13 Dec 2010 01:12:56 +0000</pubDate>
				<category><![CDATA[杂项资源]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[programming language]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=3385</guid>

					<description><![CDATA[<p>下面是一个关于编程语言流行度的图（以前本站也有一篇编程语言流行度的文章）。其X轴是从Github中取来的数据（项目数），而Y轴是从StackOverflow取来...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/3385.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/3385.html">编程语言流行度</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>下面是一个关于编程语言流行度的图（以前本站也有一篇<a href="https://coolshell.cn/articles/706.html" target="_blank">编程语言流行度的文章</a>）。其X轴是从Github中取来的数据（项目数），而Y轴是从StackOverflow取来的（tag数）。注意：Github提供了语言流行度：<a href="https://github.com/languages">https://github.com/languages</a>，而本图的原始数据在<a href="http://www.dataists.com/wp-content/uploads/2010/12/language_ranks1.csv" target="_blank">这里</a>。</p>
<figure id="attachment_3386" aria-describedby="caption-attachment-3386" style="width: 581px" class="wp-caption aligncenter"><a href="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1.png"><img decoding="async" loading="lazy" class="size-large wp-image-3386   " title="编程语言流行度" src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-1024x768.png" alt="" width="581" height="436" srcset="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-1024x768.png 1024w, https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-300x225.png 300w, https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-768x576.png 768w, https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-360x270.png 360w" sizes="(max-width: 581px) 100vw, 581px" /></a><figcaption id="caption-attachment-3386" class="wp-caption-text">编程语言流行度（点击看大图）</figcaption></figure>
<p>来源：<a href="http://www.dataists.com/2010/12/ranking-the-popularity-of-programming-langauges/" target="_blank">http://www.dataists.com/2010/12/ranking-the-popularity-of-programming-langauges/</a><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution-150x150.jpg" alt="编程语言进化" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_title">编程语言进化</a></li><li ><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-150x150.jpg" alt="计算机编程简史图" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_title">计算机编程简史图</a></li><li ><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/22.jpg" alt="五个编程语言设计的失误" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_title">五个编程语言设计的失误</a></li><li ><a href="https://coolshell.cn/articles/2539.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/1.jpg" alt="参透软件开发的本质 &#8211; Uncle Bob Martin 推荐的经典书籍" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2539.html" class="wp_rp_title">参透软件开发的本质 &#8211; Uncle Bob Martin 推荐的经典书籍</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/3385.html">编程语言流行度</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/3385.html/feed</wfw:commentRss>
			<slash:comments>6</slash:comments>
		
		
			</item>
		<item>
		<title>编程语言进化</title>
		<link>https://coolshell.cn/articles/3100.html</link>
					<comments>https://coolshell.cn/articles/3100.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Mon, 11 Oct 2010 01:18:27 +0000</pubDate>
				<category><![CDATA[编程语言]]></category>
		<category><![CDATA[programming language]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=3100</guid>

					<description><![CDATA[<p>以前本站发布过《编程语言时间地理图》、《计算机编程简史图》，下面是两张关于编程语言的进化图。 第一张是比较宏观的，来源在这里，虽然是去年的，但还是比较不错的，其...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/3100.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/3100.html">编程语言进化</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script></p>
<p style="text-align: left;">以前本站发布过《<a rel="bookmark" href="https://coolshell.cn/articles/1863.html" target="_blank">编程语言时间地理图</a>》、《<a rel="bookmark" href="https://coolshell.cn/articles/2724.html" target="_blank">计算机编程简史图</a>》，下面是两张关于编程语言的进化图。</p>
<p style="text-align: left;">第一张是比较宏观的，<a href="http://techdistrict.kirkk.com/2009/06/17/the-new-era-of-programming-languages/" target="_blank">来源在这里</a>，虽然是去年的，但还是比较不错的，其把计算机编程语言分成了五个时代——</p>
<p style="text-align: center;"><a href="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution.jpg"><img decoding="async" loading="lazy" title="language-evolution" src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution.jpg" alt="" width="600" height="379" /></a></p>
<ul>
<li><strong>语言诞生</strong>。1940年代。第一个语言应该是：<a href="http://en.wikipedia.org/wiki/Ada_Lovelace" target="_blank">Ada Lovelace</a>,</li>
<li><strong>编译器时代</strong>。1950年代。这个时代的代表语言是：Fortran, LISP, 和 COBOL，编程语言开始引入编译器优化技术。</li>
<li><strong>模式时代</strong>。1960年代-1970年代。这个时代是编程语言最重大的变革。在这个时代，所有人都在思考如何让设计一个好的编程语言以让编程更简单。面向对象也因为Simula而出现，而Smalltalk成了第一个纯动态类型的语言，C/C++、Pascal和SQL也是这个时代出现的，而第一个功能性/函数式语言ML也是这个时代出现的。所以说，这个时代是一个百花齐放的时代。而1980年代并没有太多的创新的东西，而只是对70年代出现的那些语言优化和发展的时期，如：1979年发明的C++语言。</li>
<li><strong>生产力时代</strong>。1990年代以来主要是如何增进编程生产率的时代，这个时代出现了很多framework，代码库，以及快速开发的IDE，很多公司都在这个时期致力于这些增进生率的工作，如：delphi, power builder, MFC，boost等等。但最重要的还是因为引入了虚拟机——WORA（Write Once, Run Anywhere），JVM 是这方面的代表作。之后的.NET整出来的那些东西都是。今天的JPython, JRuby等都是为整合开发效率和维护效率。参看《<a rel="bookmark" href="https://coolshell.cn/articles/247.html">基于JVM的语言正在开始流行</a>》</li>
<li><strong>后现代</strong>。未来的编程语言要走向何方，我不太清楚，不过，大家可以看看本站的这几篇文章：《<a rel="bookmark" href="https://coolshell.cn/articles/2598.html">五个编程语言设计的失误</a>》、《<a href="https://coolshell.cn/articles/209.html" target="_blank">C++和JAVA传统中积极的一面</a>》</li>
</ul>
<p style="text-align: center;">
<p style="text-align: left;">下面是一张大图，让你看看整个编程语言的进代图。（点击看大图）</p>
<p style="text-align: left;"><span id="more-3100"></span></p>
<p style="text-align: center;"><a href="https://coolshell.cn/wp-content/uploads/2010/10/EvolutionOfComputerlanguages.png"><img decoding="async" loading="lazy" class="size-large wp-image-3103 aligncenter" title="Evolution Of Computer Languages" src="https://coolshell.cn/wp-content/uploads/2010/10/EvolutionOfComputerlanguages-1024x727.png" alt="" width="675" height="480" srcset="https://coolshell.cn/wp-content/uploads/2010/10/EvolutionOfComputerlanguages-1024x727.png 1024w, https://coolshell.cn/wp-content/uploads/2010/10/EvolutionOfComputerlanguages-300x213.png 300w, https://coolshell.cn/wp-content/uploads/2010/10/EvolutionOfComputerlanguages.png 1529w" sizes="(max-width: 675px) 100vw, 675px" /></a> <a href="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution.jpg"></a></p>
<p style="text-align: left;"><a href="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution.jpg">（</a>全文完）</p>
<p><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-150x150.png" alt="编程语言流行度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_title">编程语言流行度</a></li><li ><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-150x150.jpg" alt="计算机编程简史图" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_title">计算机编程简史图</a></li><li ><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/22.jpg" alt="五个编程语言设计的失误" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_title">五个编程语言设计的失误</a></li><li ><a href="https://coolshell.cn/articles/2539.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/1.jpg" alt="参透软件开发的本质 &#8211; Uncle Bob Martin 推荐的经典书籍" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2539.html" class="wp_rp_title">参透软件开发的本质 &#8211; Uncle Bob Martin 推荐的经典书籍</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/3100.html">编程语言进化</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/3100.html/feed</wfw:commentRss>
			<slash:comments>11</slash:comments>
		
		
			</item>
		<item>
		<title>计算机编程简史图</title>
		<link>https://coolshell.cn/articles/2724.html</link>
					<comments>https://coolshell.cn/articles/2724.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Sun, 25 Jul 2010 23:54:16 +0000</pubDate>
				<category><![CDATA[Unix/Linux]]></category>
		<category><![CDATA[技术读物]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[programming language]]></category>
		<category><![CDATA[Unix]]></category>
		<category><![CDATA[算法]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=2724</guid>

					<description><![CDATA[<p>这个图片太经典了，本来想翻译的，后来觉得这么经典的图片可能早已被人翻译了，简单的Google一下，果然有人翻译了。那我就把英文版和中文版都转过来吧。我们可以看到...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/2724.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/2724.html">计算机编程简史图</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>这个图片太经典了，本来想翻译的，后来觉得这么经典的图片可能早已被人翻译了，简单的Google一下，果然有人翻译了。那我就把英文版和中文版都转过来吧。我们可以看到，其中很大一部分人都和Unix有着不解之缘（参见《<a rel="bookmark" href="https://coolshell.cn/articles/2322.html" target="_blank">Unix传奇上篇</a>，<a href="https://coolshell.cn/articles/2324.html" target="_blank">Unix传奇下篇</a>》）</p>
<ul>
<li><a href="http://www.smashingmagazine.com/2010/06/06/designing-the-world-of-programming-infographic/" target="_blank">英文原版</a></li>
<li><a href="http://www.mazingtech.com/cn/list.aspx/News/1/%E5%9B%BE%E8%AF%B4%E8%AE%A1%E7%AE%97%E6%9C%BA%E7%BC%96%E7%A8%8B%E7%AE%80%E5%8F%B2" target="_blank">中文翻译版</a></li>
</ul>
<p>什么也不说了，直接上图（图片比较大，单击图片看大图）</p>
<hr />
<figure id="attachment_2726" aria-describedby="caption-attachment-2726" style="width: 409px" class="wp-caption aligncenter"><a href="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_.jpg"><img decoding="async" loading="lazy" class="size-large wp-image-2726" title="计算机编程简史图（英文版） " src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-409x1024.jpg" alt="" width="409" height="1024" /></a><figcaption id="caption-attachment-2726" class="wp-caption-text">计算机编程简史图（英文版） </figcaption></figure>
<hr />
<p><span id="more-2724"></span></p>
<p><figure id="attachment_2725" aria-describedby="caption-attachment-2725" style="width: 409px" class="wp-caption aligncenter"><a href="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04_cn.jpg"><img decoding="async" loading="lazy" class="size-large wp-image-2725" title="计算机编程简史图（中文版） " src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04_cn-409x1024.jpg" alt="" width="409" height="1024" srcset="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04_cn-409x1024.jpg 409w, https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04_cn-120x300.jpg 120w, https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04_cn.jpg 1200w" sizes="(max-width: 409px) 100vw, 409px" /></a><figcaption id="caption-attachment-2725" class="wp-caption-text">计算机编程简史图（中文版） </figcaption></figure><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/19996.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2019/11/ken.dennis-300x186-1-150x150.jpeg" alt="Unix 50 年：Ken Thompson 的密码" width="150" height="150" /></a><a href="https://coolshell.cn/articles/19996.html" class="wp_rp_title">Unix 50 年：Ken Thompson 的密码</a></li><li ><a href="https://coolshell.cn/articles/18360.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2018/05/300x262-150x150.jpg" alt="程序员练级攻略（2018)  与我的专栏" width="150" height="150" /></a><a href="https://coolshell.cn/articles/18360.html" class="wp_rp_title">程序员练级攻略（2018)  与我的专栏</a></li><li ><a href="https://coolshell.cn/articles/17998.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2017/07/systemd-1-150x150.jpeg" alt="Linux PID 1 和 Systemd" width="150" height="150" /></a><a href="https://coolshell.cn/articles/17998.html" class="wp_rp_title">Linux PID 1 和 Systemd</a></li><li ><a href="https://coolshell.cn/articles/12103.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2014/11/tux-fork-150x150.gif" alt="vfork 挂掉的一个问题" width="150" height="150" /></a><a href="https://coolshell.cn/articles/12103.html" class="wp_rp_title">vfork 挂掉的一个问题</a></li><li ><a href="https://coolshell.cn/articles/12052.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/29.jpg" alt="Leetcode 编程训练" width="150" height="150" /></a><a href="https://coolshell.cn/articles/12052.html" class="wp_rp_title">Leetcode 编程训练</a></li><li ><a href="https://coolshell.cn/articles/11847.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2014/08/puzzle-150x150.png" alt="谜题的答案和活动的心得体会" width="150" height="150" /></a><a href="https://coolshell.cn/articles/11847.html" class="wp_rp_title">谜题的答案和活动的心得体会</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/2724.html">计算机编程简史图</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/2724.html/feed</wfw:commentRss>
			<slash:comments>32</slash:comments>
		
		
			</item>
		<item>
		<title>五个编程语言设计的失误</title>
		<link>https://coolshell.cn/articles/2598.html</link>
					<comments>https://coolshell.cn/articles/2598.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Wed, 14 Jul 2010 00:38:34 +0000</pubDate>
				<category><![CDATA[程序设计]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[programming language]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=2598</guid>

					<description><![CDATA[<p>在近几年来，编程语言的设计正在经历着类似于“文艺复兴”的过程，这么说主要是基于下面两个事实：1）多核技术推动着PC消费者更多的关注并行程序。2）动态语言的性能越...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/2598.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/2598.html">五个编程语言设计的失误</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>在近几年来，编程语言的设计正在经历着类似于“文艺复兴”的过程，这么说主要是基于下面两个事实：1）多核技术推动着PC消费者更多的关注并行程序。2）动态语言的性能越来越好，其性期已经可以足够用来实现互联网服务，并且它们正在走出“脚本语言”阴影。</p>
<p>这篇文章试图收集最重要的编程语言的设计错误，以便让那些程序语言设计者们在设计新型的编程语言时避免。我避免了一些纠缠不清的有好有坏的问题，如：动态类型或是静态类型。我也省略了那些看起来并不严重，很容易被修改的错误。例如，加入“参量”（Parametric Type），这在Java中已经有了。Sun在发布Java 1.0版后的第八年才加入了这一功能。还有一个最近的例子是 <a href="http://golang.org/doc/go_lang_faq.html#generics" target="_blank">Google Go Language Design FAQ</a> 中说到的：: &#8220;Generics may well be added at some point. We don&#8217;t feel an urgency for them, although we understand some programmers do.&#8221;</p>
<h3>0. Null 指针</h3>
<p>几乎在所有的主流编程语言中，对一个对像的引用可能会是一个空指针，这个错误会引发运行时错误。 C.A.R. Hoare 最近声明向这一“发明”负责，尽管如此，其它许多的设计者们都应该对这样的设计受到批评。下面是 C.A.R Hoare 的“忏悔”：</p>
<blockquote><p>I call it my billion-dollar mistake. It was the invention of the null reference in 1965. [&#8230;] More recent programming languages like Spec# have introduced declarations for non-null references. This is the solution, which I rejected in 1965. &#8211; <a href="http://qconlondon.com/london-2009/presentation/Null+References:+The+Billion+Dollar+Mistake" target="_blank">C.A.R. Hoare</a></p>
<p>我把它叫做“亿万美元错误”。这个空指针的发明创造来自1965年。…… 现在的编程语言引入了“非空引用”的声明规格。这个方案被我在1965年给拒绝了。</p></blockquote>
<p><span id="more-2598"></span></p>
<p>其它语言，如 C/C++ 更夸张，它们在运到这样的错误时，直接Crash掉，而 Java， Python 和其它语言会抛出一NullPointerException异常，但问题是，这个 RuntimeException 可能会被几乎所有的语句抛出。其实，只需要一个静态类型的语言就可以保证不会出现空指针或空引用。例如： <a href="http://cyclone.thelanguage.org/" target="_blank">Cyclone</a> 是一个安全的C变种，其引入了非空指针和指针运算的限制。</p>
<p>一些语言甚至让你根本不可能创建空指针，虽然这使得明确的指针不能行进行运算。Haskell 就是这样的一个语言，其提供了Maybe Monad，其强制程序员考虑“Null”的情形。</p>
<h3>1. 很难解析的语法</h3>
<p>编程语言的语法应该来自 <a href="http://en.wikipedia.org/wiki/LALR_parser" target="_blank">LALR</a> 或是更好的 <a href="http://en.wikipedia.org/wiki/LL_parser" target="_blank">LL(1)</a>。今天的程序员需要适当的工具来支持其开发语言，也就是我们常说的IDE，编译器或是其它可以帮你解析程序语言的编程工具。这并不会出现在一个单一的前端。也许，多重编译器已经被实现出来了。这可能让我们的开始变得更容易一些。然而，我们现实中的一个反例是 C++，几乎没有哪个C++的编译器可以把C++这个语言完美地正确地解释出来，而且不同C++的编译器的行为如此的诡异。编程语法的开销是微不足道的，程序员应该在编写程序中享有更快速和高效的回报。</p>
<h3>2. 未定义的语义</h3>
<p>别在语言规格中说“实现规范”！尽可能的少使用“未定义”这样的术语来描述语言的行为（C/C++中出现了很多undefined的行为）！黄金准则是StandardML，其是一个完整地正式的语义。C 语言是这样一个反例，其规则中有太多太多的未定义的情况。然而，由于其广泛使用，所以某些行为的定义已经成为了世界的共识（江湖的行规，或，潜规则）。 举个例子，在C中，整型 overflow 的行为是未定义的，而编译器也是有能力推断出“ <code>x &lt; x+1</code> ”是否总是为真。不幸的是，这个本来是编译器应该干的事，交给了程序员，于是在C的世界里，出现了大量的整型溢出的代码。而当整型溢出的时候，几乎所有的行为都是像x86处理器一样（如： <code>maxint+1 == minint）。</code></p>
<p>明确的语义可以让验证和错误检查更容易。虽然，软件校验来得比缓慢，但一定会来。我可以想像，编程语言的下一个机会将会是更容易地校验，这可能需要十到二十年的时间，但今天开始这样做的语言将会在那天成为世界的主流。</p>
<h3>3. 坏的Unicode 支持</h3>
<p>程序中几乎都要处理字符串，但别忘了并不是所有人都会使用英语来编程。今天，几乎所有的编程语言都不支持Unicode，所以，我们只能使用ANSI的英语来编程。这个时代， 程序员应该使用Unicode 来编程，所以，源代码也可以声明其用什么来编码。</p>
<p>在文本和字节序间的转换和区分在的标准库方面会比语言方面更是一个问题，当然，这也影响了语法。读一读 <a href="http://docs.python.org/py3k/whatsnew/3.0.html#text-vs-data-instead-of-unicode-vs-8-bit" target="_blank">Python 3 是怎么解决这个问题</a>可能会更有一些帮助。</p>
<h3>4. 预处理器</h3>
<p>像C++和MP4的预处理器已经被广泛地使用着，使用预处理器更像是一种hack而不是一个干净的解决方案。 他们被用来，使用外部文件（如头文件，但确没有正确地模块机制），使用条件编译，宏替换，等。把这些功能与编程语言集成起来一起使用可以增加程序的性能和开发效率，并没有什么不好的地方。</p>
<p>如果要举一个反例，那么就是预编译器的模块化系统。C使用<code>#include</code> 而 C++ 更痛苦，因为模板需要写一个大的头文件，而且其会被包含在几乎所有的其它文件中。而一个真正的模块化的系统是不需要使用 <code>extern</code> 关键字，也不需要程序的链接，而应该是直接使用。</p>
<h2></h2>
<p>文章：<a href="http://beza1e1.tuxen.de/articles/proglang_mistakes.html" target="_blank">来源</a><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-150x150.png" alt="编程语言流行度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_title">编程语言流行度</a></li><li ><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution-150x150.jpg" alt="编程语言进化" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_title">编程语言进化</a></li><li ><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-150x150.jpg" alt="计算机编程简史图" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_title">计算机编程简史图</a></li><li ><a href="https://coolshell.cn/articles/2539.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/1.jpg" alt="参透软件开发的本质 &#8211; Uncle Bob Martin 推荐的经典书籍" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2539.html" class="wp_rp_title">参透软件开发的本质 &#8211; Uncle Bob Martin 推荐的经典书籍</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/2598.html">五个编程语言设计的失误</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/2598.html/feed</wfw:commentRss>
			<slash:comments>8</slash:comments>
		
		
			</item>
		<item>
		<title>参透软件开发的本质 &#8211; Uncle Bob Martin 推荐的经典书籍</title>
		<link>https://coolshell.cn/articles/2539.html</link>
					<comments>https://coolshell.cn/articles/2539.html#comments</comments>
		
		<dc:creator><![CDATA[jnj]]></dc:creator>
		<pubDate>Mon, 05 Jul 2010 00:30:29 +0000</pubDate>
				<category><![CDATA[技术读物]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[book]]></category>
		<category><![CDATA[programming language]]></category>
		<category><![CDATA[软件开发]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=2539</guid>

					<description><![CDATA[<p>数量级25（10^25）是 Uncle Bob 在 RailsConf 演讲的主题。如果你用一台 PDP 8（ 1960年代的计算机）和 Mac PowerBo...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/2539.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/2539.html">参透软件开发的本质 – Uncle Bob Martin 推荐的经典书籍</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>数量级25（10^25）是 Uncle Bob 在 <a href="http://en.oreilly.com/rails2010">RailsConf</a> 演讲的主题。如果你用一台 PDP 8（ 1960年代的计算机）和 Mac PowerBook 做比较的话，你会发现 Mac PowerBook 比 PDP 8 快8000倍，有6百万倍大的内存，11000倍的耗能，1500倍的容量等等。如果将这些0累加起来，很容易达到10^25。在过去40年里，我们的硬件计算能力获得了10^25倍的提升，而作为软件开发人员的我们并没有利用这些计算能力来提升多少我们的软件开发能力。没错，我们是写了不少的代码，但是它们基本上都是一些顺序语句，if 语句，和 while 循环等，没有什么新鲜的东西。你可能会说面向对象是新东西呀，但是那只是另外一种组织顺序、选择和迭代等语句的方法而已。除我们现有的编程语言之外，如果有新的编程语言能够产生并创造新的“微积分学”，从而将软件开发提高到一个新的高度，将会是一件非常令人期待的事情，因为顺序语句，选择语句和迭代等最终将成为历史。</p>
<p>Uncle Bob 认为以下四本书是软件开发人员必须阅读的，并由他自己来排名。</p>
<p>1. The Structure &amp; Interpretation of Computer Programs 计算机程序的构造和解释 （By Harold Abelson &amp; Gerald Sussman）</p>
<p>书中使用的是 Scheme 语言（Lisp 的一个变种），此书的内容曾经是 MIT 计算机系的一门课程，当然现在已经不是了。</p>
<p>2. Structured Programming 结构化程序设计 （By Edsger W. Dijkstra）</p>
<p>相信软件专业的同学们都上过此课程，我们的启蒙书籍。这本书讨论了 go to 是怎样的邪恶，同时也讨论了面向对象。对比一下今天我们视为 best practice 的测试驱动开发（TDD），go to 在过去也曾经是 Fortran，Cobol 等语言的核心。</p>
<p>3. The Annotated TURING （By Charles Petzold）</p>
<p>Uncle Bob 令人尴尬地忘记了这本书的名字，他自嘲说自己从来记不住这本书名。但是此书在他的推荐列表中列第三位。</p>
<p>4. Clean Code （By Robert C. Martin）</p>
<p>Uncle Bob 本人的大作。</p>
<p>我的一位同事将这位 Uncle Bob 视为软件开发领域中的上帝，Uncle Bob 这位大师在当下各类编程语言和平台层出不穷的时候，在我们为该学什么语言买什么书举棋不定的时候，推荐给读者这几本经典，也许是煞费苦心地想让我们参透软件开发的本质吧。不过会不会也是因为我们都在慢慢变老，许多旧的东西如今又变成了新鲜有趣的事情啦？（出自采访记者之口）</p>
<p><a href="http://vimeo.com/12957619"><em>文章来源</em></a><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-150x150.png" alt="编程语言流行度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_title">编程语言流行度</a></li><li ><a href="https://coolshell.cn/articles/3270.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/11/Learn-Python-The-Hard-Way-150x150.jpg" alt="两本电子书" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3270.html" class="wp_rp_title">两本电子书</a></li><li ><a href="https://coolshell.cn/articles/3192.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/Intel-Recommended-Books-for-Developers-150x150.jpg" alt="一些非常不错的资料" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3192.html" class="wp_rp_title">一些非常不错的资料</a></li><li ><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution-150x150.jpg" alt="编程语言进化" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_title">编程语言进化</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/2539.html">参透软件开发的本质 – Uncle Bob Martin 推荐的经典书籍</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/2539.html/feed</wfw:commentRss>
			<slash:comments>9</slash:comments>
		
		
			</item>
		<item>
		<title>程序员眼中的编程语言</title>
		<link>https://coolshell.cn/articles/1992.html</link>
					<comments>https://coolshell.cn/articles/1992.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Thu, 24 Dec 2009 06:31:25 +0000</pubDate>
				<category><![CDATA[编程语言]]></category>
		<category><![CDATA[轶事趣闻]]></category>
		<category><![CDATA[C++]]></category>
		<category><![CDATA[Java]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Programmer]]></category>
		<category><![CDATA[programming language]]></category>
		<category><![CDATA[Ruby]]></category>
		<category><![CDATA[程序员]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=1992</guid>

					<description><![CDATA[<p>下图是一个搞笑的图片——程序员眼中的编程语言。 图片的横轴是编程语言。 纵轴是各语言的程序员、粉丝、信徒。 中间的各个小图片则是，粉丝眼中的编程语言的形象。 比...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/1992.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/1992.html">程序员眼中的编程语言</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>下图是一个搞笑的图片——程序员眼中的编程语言。</p>
<ul>
<li>图片的横轴是编程语言。</li>
<li>纵轴是各语言的程序员、粉丝、信徒。</li>
<li>中间的各个小图片则是，粉丝眼中的编程语言的形象。</li>
</ul>
<p>比如说，</p>
<ul>
<li>第一行第一列，是Java程序员看Java语言的样子，一幢现代化的大厦。</li>
<li>第一行第二列，是Java程序员看C语言，一个年老过时的骨灰级老头。</li>
<li>当然，C程序员看Java语言也比较搞，见第二行第一列。呵呵。</li>
</ul>
<p>其它的大家自己看吧。还有另外一个关于操作系统的《<a rel="bookmark" href="https://coolshell.cn/articles/1998.html">粉丝眼中的操作系统</a>》</p>
<p style="text-align: center;"><img decoding="async" loading="lazy" class="alignnone size-full wp-image-1994" title="程序员眼中的编程语言" src="https://coolshell.cn/wp-content/uploads/2009/12/language-fanboys.jpg" alt="程序员眼中的编程语言" width="575" height="420" srcset="https://coolshell.cn/wp-content/uploads/2009/12/language-fanboys.jpg 575w, https://coolshell.cn/wp-content/uploads/2009/12/language-fanboys-300x219.jpg 300w, https://coolshell.cn/wp-content/uploads/2009/12/language-fanboys-370x270.jpg 370w" sizes="(max-width: 575px) 100vw, 575px" /></p>
<p> </p>
<p><a href="https://coolshell.cn/wp-content/uploads/2009/12/language-fanboys.jpg"></a><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/18360.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2018/05/300x262-150x150.jpg" alt="程序员练级攻略（2018)  与我的专栏" width="150" height="150" /></a><a href="https://coolshell.cn/articles/18360.html" class="wp_rp_title">程序员练级攻略（2018)  与我的专栏</a></li><li ><a href="https://coolshell.cn/articles/8088.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/7.jpg" alt="对技术的态度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/8088.html" class="wp_rp_title">对技术的态度</a></li><li ><a href="https://coolshell.cn/articles/4990.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2011/07/programmer-150x150.png" alt="程序员技术练级攻略" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4990.html" class="wp_rp_title">程序员技术练级攻略</a></li><li ><a href="https://coolshell.cn/articles/4758.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/30.jpg" alt="如何写出无法维护的代码" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4758.html" class="wp_rp_title">如何写出无法维护的代码</a></li><li ><a href="https://coolshell.cn/articles/4102.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/25.jpg" alt="如何学好C语言" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4102.html" class="wp_rp_title">如何学好C语言</a></li><li ><a href="https://coolshell.cn/articles/1391.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/18.jpg" alt="编程真难啊" width="150" height="150" /></a><a href="https://coolshell.cn/articles/1391.html" class="wp_rp_title">编程真难啊</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/1992.html">程序员眼中的编程语言</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/1992.html/feed</wfw:commentRss>
			<slash:comments>33</slash:comments>
		
		
			</item>
		<item>
		<title>编程语言时间地理图</title>
		<link>https://coolshell.cn/articles/1863.html</link>
					<comments>https://coolshell.cn/articles/1863.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Sun, 29 Nov 2009 23:33:04 +0000</pubDate>
				<category><![CDATA[技术读物]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[programming language]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=1863</guid>

					<description><![CDATA[<p> 有人使用Google Map做了一个网页，把所有编程语言的时间线和地理位置，如下图，上面是一个编程语言的时间轴，下面是Google Map地图，点击编程语言，...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/1863.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/1863.html">编程语言时间地理图</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script></p>
<p style="text-align: left;"> 有人使用Google Map做了一个<a href="http://www.geospat.com/hoprola/" target="_blank">网页</a>，把所有编程语言的时间线和地理位置，如下图，上面是一个编程语言的时间轴，下面是Google Map地图，点击编程语言，你可以查看该编程语言的发明者，发明地，和其Hello World示例（点击<a href="https://coolshell.cn/articles/169.html" target="_blank">这里</a>查看更多的Hello World）</p>
<p style="text-align: center;"><a href="http://www.geospat.com/hoprola/" target="_blank"><strong>http://www.geospat.com/hoprola/</strong></a><br />
<a href="https://coolshell.cn/wp-content/uploads/2009/11/programming_language_timeline.jpg" target="_blank"><img decoding="async" loading="lazy" title="编程语言时间地理图（点击看大图）" src="https://coolshell.cn/wp-content/uploads/2009/11/programming_language_timeline.jpg" alt="编程语言时间地理图" width="1013" height="606" /></a></p>
<p style="text-align: center;"><img decoding="async" loading="lazy" class="alignnone size-full wp-image-1861" title="JavaScript 的发明者，发明地和示例" src="https://coolshell.cn/wp-content/uploads/2009/11/programming_language_timeline_javascript.jpg" alt="JavaScript 的发明者，发明地和示例" width="330" height="297" srcset="https://coolshell.cn/wp-content/uploads/2009/11/programming_language_timeline_javascript.jpg 330w, https://coolshell.cn/wp-content/uploads/2009/11/programming_language_timeline_javascript-300x270.jpg 300w" sizes="(max-width: 330px) 100vw, 330px" /></p>
<p style="text-align: center;">（点击小星，可以看到语言的发明者和示例）</p>
<p><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-150x150.png" alt="编程语言流行度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_title">编程语言流行度</a></li><li ><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution-150x150.jpg" alt="编程语言进化" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_title">编程语言进化</a></li><li ><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-150x150.jpg" alt="计算机编程简史图" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_title">计算机编程简史图</a></li><li ><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/22.jpg" alt="五个编程语言设计的失误" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_title">五个编程语言设计的失误</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/1863.html">编程语言时间地理图</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/1863.html/feed</wfw:commentRss>
			<slash:comments>8</slash:comments>
		
		
			</item>
		<item>
		<title>BT雷人的程序语言</title>
		<link>https://coolshell.cn/articles/1142.html</link>
					<comments>https://coolshell.cn/articles/1142.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Sun, 12 Jul 2009 03:07:03 +0000</pubDate>
				<category><![CDATA[编程语言]]></category>
		<category><![CDATA[轶事趣闻]]></category>
		<category><![CDATA[brainfuck]]></category>
		<category><![CDATA[LOLCODE]]></category>
		<category><![CDATA[programming language]]></category>
		<category><![CDATA[WhiteSpace]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=1142</guid>

					<description><![CDATA[<p>这个世界从来都不会缺少另类的东西，人类自然世界如此，计算机世界也一样。编程语言方面，看过本站《6个变态的C语言Hello World程序》的朋友们一定对BT和另...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/1142.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/1142.html">BT雷人的程序语言</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>这个世界从来都不会缺少另类的东西，人类自然世界如此，计算机世界也一样。编程语言方面，看过本站《<a title="6个变态的C语言Hello World程序 - 661次点击" href="../?p=914">6个变态的C语言Hello World程序</a>》的朋友们一定对BT和另类不会陌生，但那都是些小儿科，真正的BT和另类要是从语言级上来完成。让我们来看看其中一个比较另类的语言BrainFuck。看到这个程序语言的名字，请不要以为这是一个搞笑的语言，这是一个“严肃事情”，请大家用“最虔诚的态度”来阅读本文。</p>
<h4>BF语言介绍</h4>
<p><strong>Brainfuck</strong>，是一种极小化的计算机语言，它是由Urban Müller在1993年创建的。由于“绿王八”的原因，这种语言有时被称为<strong>brainf**k</strong>或<strong>brainf***</strong>，甚至被简称为<strong>BF</strong>。这种 语言，是一种按照“Turing complete（完整图灵机）”思想设计的语言，它的主要设计思路是：用最小的概念实现一种“简单”的语言，BrainF**k 语言只有八种符号，所有的操作都由这八种符号的组合来完成。</p>
<p>BF基于一个简单的机器模型，除了八个指令，这个机器还包括：一个以字节为单位、被初始化为零的数组、一个指向该数组的指针(初始时指向数组的第一个字节)、以及用于输入输出的两个字节流。</p>
<p>下面是这八种指令的描述，其中每个指令由一个字符标识：</p>
<p><span id="more-1142"></span></p>
<table border="0">
<tbody>
<tr>
<th>字符</th>
<th>含义</th>
</tr>
<tr>
<td><code>&gt;</code></td>
<td>指针加一</td>
</tr>
<tr>
<td><code>&lt;</code></td>
<td>指针减一</td>
</tr>
<tr>
<td><code>+</code></td>
<td>指针指向的字节的值加一</td>
</tr>
<tr>
<td><code>-</code></td>
<td>指针指向的字节的值减一</td>
</tr>
<tr>
<td><code>.</code></td>
<td>输出指针指向的单元内容（ASCII码）</td>
</tr>
<tr>
<td><code>,</code></td>
<td>输入内容到指针指向的单元（ASCII码）</td>
</tr>
<tr>
<td><code>[</code></td>
<td>如果指针指向的单元值为零，向后跳转到对应的<code>]</code>指令的次一指令处</td>
</tr>
<tr>
<td><code>]</code></td>
<td>如果指针指向的单元值不为零，向前跳转到对应的<code>[</code>指令的次一指令处</td>
</tr>
</tbody>
</table>
<p>（按照更节省时间的简单说法，<code>]</code>也可以说成“向后跳转到对应的<code>[</code>状态”。这两解释是一样的。）</p>
<p>（第三种同价的说法，<code>[</code>意思是&#8221;向前跳转到对应的<code>]</code>&#8220;，<code>]</code>意思是&#8221;向后跳转到对应的<code>[</code>指令的次一指令处，如果指针指向的字节非零。&#8221;）</p>
<p>Brainfuck程序可以用下面的替换方法翻译成C语言（假设<code>ptr</code>是<code>char*</code>类型）：</p>
<table border="0">
<tbody>
<tr>
<th>Brainfuck</th>
<th>C</th>
</tr>
<tr>
<td align="center"><code>&gt;</code></td>
<td><code>++ptr;</code></td>
</tr>
<tr>
<td align="center"><code>&lt;</code></td>
<td><code>--ptr;</code></td>
</tr>
<tr>
<td align="center"><code>+</code></td>
<td><code>++*ptr;</code></td>
</tr>
<tr>
<td align="center"><code>-</code></td>
<td><code>--*ptr;</code></td>
</tr>
<tr>
<td align="center"><code>.</code></td>
<td><code>putchar(*ptr);</code></td>
</tr>
<tr>
<td align="center"><code>,</code></td>
<td><code>*ptr =getchar();</code></td>
</tr>
<tr>
<td align="center"><code>[</code></td>
<td><code>while (*ptr) {</code></td>
</tr>
<tr>
<td align="center"><code>]</code></td>
<td><code>}</code></td>
</tr>
</tbody>
</table>
<h4>BF解释器</h4>
<p>因为 BrainFuck 只有八种指令，并且没有关键字，也不允许自定义标识符，因此它的编译器实现起来非常简单，初学 C 语言不久的人都可以自己编出来，尽管在座的各位每人都可以自己编一个，不过为了引起大家的兴趣，我这里还是给出大家一个官方发布的版本。这个程序只有短短 50 多行，并且完全由 ANSI C 写成，因此你随便找个 C 语言编译器，把它编译一下。</p>
<pre data-enlighter-language="c" class="EnlighterJSRAW">
#include &lt;stdio.h&gt;;

int  p, r, q;
char a[5000], f[5000], b, o, *s=f;

void interpret(char *c)
{
    char *d;

    r++;
    while( *c ) {
        //if(strchr(&quot;&lt;&gt;;+-,.[]\n&quot;,*c))printf(&quot;%c&quot;,*c);
        switch(o=1,*c++) {
            case &#039;&lt;&#039;: p--;        break;
            case &#039;&gt;;&#039;: p++;       break;
            case &#039;+&#039;: a[p]++;     break;
            case &#039;-&#039;: a[p]--;     break;
            case &#039;.&#039;: putchar(a[p]); fflush(stdout); break;
            case &#039;,&#039;: a[p]=getchar();fflush(stdout); break;
            case &#039;[&#039;:
                for( b=1,d=c; b &amp;&amp; *c; c++ )
                b+=*c==&#039;[&#039;, b-=*c==&#039;]&#039;;
                if(!b) {
                    c[-1]=0;
                    while( a[p] )
                    interpret(d);
                    c[-1]=&#039;]&#039;;
                    break;
                }
            case &#039;]&#039;:
                puts(&quot;UNBALANCED BRACKETS&quot;), exit(0);
            case &#039;#&#039;:
                if(q&gt;;2)
                printf(&quot;%2d %2d %2d %2d %2d %2d %2d %2d %2d %2d\n%*s\n&quot;,
                *a,a[1],a[2],a[3],a[4],a[5],a[6],a[7],a[8],a[9],3*p+2,&quot;^&quot;);
                break;
            default: o=0;
        }
        if( p&lt;0 || p&gt;;100)
            puts(&quot;RANGE ERROR&quot;), exit(0);
    }
    r--;
    //        chkabort();
}

main(int argc,char *argv[])
{
    FILE *z;

    q=argc;

    if(z=fopen(argv[1],&quot;r&quot;)) {
        while( (b=getc(z))&gt;;0 )
            *s++=b;
        *s=0;
        interpret(f);
    }
}
</pre>
<p>当然，如果你觉得用C语言来实现BrainFuck语言的解释器是对BrainFuck这种语言的一种侮辱的话，我们的BrainFuck社区是绝对不能容忍你有这种想法的。因为我们有一个使用100%纯brainfuck写成的一个编译器<strong>awib</strong>：<a href="http://code.google.com/p/awib/" target="_blank">http://code.google.com/p/awib/ </a></p>
<h4>Hello World</h4>
<pre>++++++++++[&gt;+++++++&gt;++++++++++&gt;+++&gt;+&lt;&lt;&lt;&lt;-]
&gt;++.&gt;+.+++++++..+++.&gt;++.&lt;&lt;+++++++++++++++.
&gt;.+++.------.--------.&gt;+.&gt;.</pre>
<p>怎么？看不懂吗？下面是解释：</p>
<pre>+++ +++ +++ +           initialize counter (cell #0) to 10
[                       use loop to set the next four cells to 70/100/30/10
    &gt; +++ +++ +             add  7 to cell #1
    &gt; +++ +++ +++ +         add 10 to cell #2
    &gt; +++                   add  3 to cell #3
    &gt; +                     add  1 to cell #4
    &lt;&lt;&lt; &lt; -                 decrement counter (cell #0)
]
&gt;++ .                   print 'H'
&gt;+.                     print 'e'
+++ +++ +.              print 'l'
.                       print 'l'
+++ .                   print 'o'
&gt;++ .                   print ' '
&lt;&lt;+ +++ +++ +++ +++ ++. print 'W'
&gt;.                      print 'o'
+++ .                   print 'r'
--- --- .               print 'l'
--- --- --.             print 'd'
&gt;+.                     print '!'
&gt;.                      print '\n'</pre>
<p><strong>相关链接</strong>：</p>
<ul>
<li>BF的官网：<a href="http://www.muppetlabs.com/~breadbox/bf/">http://www.muppetlabs.com/~breadbox/bf/</a>。</li>
<li>BF的Wikipedia：<a href="http://en.wikipedia.org/wiki/Brainfuck">http://en.wikipedia.org/wiki/Brainfuck</a>。</li>
</ul>
<h4>其它另类语言</h4>
<p>如果你要觉得BF已经很BT了，那么你就错了，下面这些程序语言更BT。</p>
<p><strong>WhiteSpace语言</strong></p>
<p style="padding-left: 30px;">这是一种只用空白字符（空格，TAB和回车）编程的语言，而其它可见字符统统为注释。下面是它的一个示例：</p>
<p style="padding-left: 30px;">&nbsp;</p>
<pre style="padding-left: 60px;">  		 	
	
  	
  
	
</pre>
<p style="padding-left: 30px;">什么？你什么也没有看见，这就对了，因为这正是这门语言的独特之处。访问下面这个链接查看<a href="http://compsoc.dur.ac.uk/whitespace/hworld.ws" target="_blank">Hello,World示例</a>。记得按Ctrl+A来查看程序。</p>
<p style="padding-left: 30px;">官网：<a href="http://compsoc.dur.ac.uk/whitespace/index.php">http://compsoc.dur.ac.uk/whitespace/index.php</a>。</p>
<p><strong>LOLCODE语言</strong></p>
<p style="padding-left: 30px;">LOLCODE是一种建立在高度缩写的网络英语之上的编程语言，一般来说如果一个人能理解这种网络英语就能在未经训练的情况下读懂LOLCODE程序源代码。下面是其Hello,World例程：</p>
<pre style="padding-left: 60px;">HAI
CAN HAS STDIO?
VISIBLE "HAI WORLD!"
KTHXBYE</pre>
<p style="padding-left: 30px;">翻译成中文就是：</p>
<pre style="padding-left: 60px;">嗨
我可以用 STDIO 么？
显示一下 “HAI WORLD!”
谢谢啊，再见</pre>
<p style="padding-left: 30px;">&nbsp;</p>
<p style="padding-left: 30px;">官网：<a href="http://lolcode.com/">http://lolcode.com/</a></p>
<p><strong>中文编程语言</strong></p>
<p style="padding-left: 30px;">不要以为只有老外才那么BT，咱们中国也有自己的BT编程语言。</p>
<p style="padding-left: 30px;"><strong>中文Basic</strong></p>
<table border="0">
<tbody>
<tr>
<td>中文指令</td>
<td></td>
<td>对应于的Applesoft BASIC</td>
</tr>
<tr>
<td><tt>10 卜=0</tt></td>
<td></td>
<td><tt>10 Y=0</tt></td>
</tr>
<tr>
<td><tt>20 <span>入</span> 水, 火</tt></td>
<td></td>
<td><tt>20 INPUT E, F</tt></td>
</tr>
<tr>
<td><tt>30 <span>從</span> 日 = 水 <span>到</span> 火</tt></td>
<td></td>
<td><tt>30 FOR A = E TO F</tt></td>
</tr>
<tr>
<td><tt>40 卜 = 卜+<span>對數</span>(日)</tt></td>
<td></td>
<td><tt>40 Y = Y + LOG (A)</tt></td>
</tr>
<tr>
<td><tt>50 <span>下一</span> 日</tt></td>
<td></td>
<td><tt>50 NEXT A</tt></td>
</tr>
<tr>
<td><tt>60 <span>印</span> 卜</tt></td>
<td></td>
<td><tt>60 PRINT Y</tt></td>
</tr>
</tbody>
</table>
<p style="padding-left: 60px;">官网无法访问了，只能看看Wikipedia了：<a href="http://en.wikipedia.org/wiki/Chinese_BASIC">http://en.wikipedia.org/wiki/Chinese_BASIC</a></p>
<p style="padding-left: 30px;"><strong>中蟒语言（中文Python）</strong></p>
<p style="padding-left: 60px;">下面的程序是不是很Cool？</p>
<pre style="padding-left: 60px;">#!/usr/local/bin/cpython
回答 = 读入('你认为中文程式语言有存在价值吗 ? (有/没有)')
如 回答 == '有':
写 '好吧, 让我们一起努力!'
不然 回答 == '没有':
写 '好吧,中文并没有作为程式语言的价值.'
否则:
写 '请认真考虑后再回答.'</pre>
<p style="padding-left: 60px;">官网：<a href="http://www.chinesepython.org/cgi_bin/cgb.cgi/home.html">http://www.chinesepython.org/</a></p>
<p>差不多了，该结束了，再次说明，这是一篇很严肃的文章。</p>
<p>(<strong>全文完</strong>)<!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/4458.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/10.jpg" alt="BT雷人的程序语言（大全）" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4458.html" class="wp_rp_title">BT雷人的程序语言（大全）</a></li><li ><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-150x150.png" alt="编程语言流行度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_title">编程语言流行度</a></li><li ><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution-150x150.jpg" alt="编程语言进化" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_title">编程语言进化</a></li><li ><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-150x150.jpg" alt="计算机编程简史图" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_title">计算机编程简史图</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/1142.html">BT雷人的程序语言</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/1142.html/feed</wfw:commentRss>
			<slash:comments>32</slash:comments>
		
		
			</item>
		<item>
		<title>编程语言的评测</title>
		<link>https://coolshell.cn/articles/973.html</link>
					<comments>https://coolshell.cn/articles/973.html#comments</comments>
		
		<dc:creator><![CDATA[Neo]]></dc:creator>
		<pubDate>Sat, 06 Jun 2009 14:50:49 +0000</pubDate>
				<category><![CDATA[技术读物]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[benchmark]]></category>
		<category><![CDATA[programming language]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=973</guid>

					<description><![CDATA[<p>摘要：这篇文章的原文出处在这里 我意译了整篇文章。结合计算机语言评测基准这个网站来读此文还是比较有意思。当然也不能以这个评测结果就贸然断定什么语言最好，什么语言...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/973.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/973.html">编程语言的评测</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script><strong>摘要</strong>：这篇文章的原文出处在<a href="http://gmarceau.qc.ca/blog/2009/05/speed-size-and-dependability-of.html">这里</a> 我意译了整篇文章。结合<a href="http://shootout.alioth.debian.org/">计算机语言评测基准</a>这个网站来读此文还是比较有意思。当然也不能以这个评测结果就贸然断定什么语言最好，什么语言不好。没有好不好的语言，只有适不适用于你解决问题域的语言。就文章而言请大家还是不必太过认真，就当从另一个方面来了解一下这33种编程语言吧。</p>
<p><a href="http://shootout.alioth.debian.org/">计算机语言评测基准</a>是一个由429个程序组成的集合，它评测了33个程序语言的13的重复实现的基准程序。如果你想量化的比较不同语言，那么这个是一个非常不错的资源。</p>
<p>在计算机评测基准中，评测者为了尽量让评测准确，非常谨慎的选择了13个基准程序，这13个基准程序并不针对某以特定语言有特殊的优化。对于评测选择33中语言都实现了13个基准程序。当然，除了速度这个指标外，程序基准评测同时也为每一个基准测试程序发布一个编码大小指标。非常感谢基准评测让我们看到程序设计中非常重要的一个方面：程序语言的性能和程序语言灵活性之间的矛盾。正是这个矛盾给所谓“高级编程语言”带上一个含蓄的轻蔑的意思。即，当你在使用这些高级语言编码时，你也许可以编写出漂亮的代码，但是你是如此的远离了硬件，你不可能获得更好的性能，是这样的吗？</p>
<p><span id="more-973"></span></p>
<p><a rel="attachment wp-att-976" href="https://coolshell.cn/?attachment_id=976"><img decoding="async" loading="lazy" width="457" height="457" class="aligncenter size-full wp-image-976" title="size-vs-speed-vs-depandability-context-3" src="https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-context-3.png" alt="size-vs-speed-vs-depandability-context-3" srcset="https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-context-3.png 457w, https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-context-3-150x150.png 150w, https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-context-3-300x300.png 300w, https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-context-3-200x200.png 200w, https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-context-3-270x270.png 270w" sizes="(max-width: 457px) 100vw, 457px" /></a><br />
如果我们将基准测试程序的结果放在一张XY的图表上，那么我们就可以为这张表的4个角命名。快速而复杂的语言应积聚在图表的左上角。我们把这类语言称为系统语言。简洁但慢速的语言应该聚集在右下角，我们称之为脚本语言。在右上角，应该是过时的语言。除非这些语言具有非常吸引人的特性，否则语言已经被新出现的语言所淘汰。最后在左下角，基本上找不到对应的语言，因为在这一区域的语言是理想状态的语言。在这个区域的语言是又快又短又利于使用的语言。</p>
<p>图中每一个小点就代表一种语言的一个基准程序实现，因此这图里面共有429个点，每个点的XY轴分别代表了其和最好的语言实现差距的倍数(从语言的复杂性和语言执行性能来说)，其中一些点比较分散，我们就没有在图中画出。从上面这个图我们可以看到这些粉红色点沿着Y轴(复杂性)比X轴(执行性能)分布更统一，这是不是意味着，人类在提升语言表达的灵活性上还在稳步的不断进步，而在提升语言性能方面却遇到了很多的麻烦呢：）</p>
<p>针对每一个种语言，比如说scala语言，我们用下面的图来描述：图的中心点，是这个语言测试结果的平均值，然后做每一个评测结果的具体值到这个均值的连线就够成了一个星型图。这个图说明了scala一些特性，在X轴性能上来说，大部分点都分布在靠近左边，说明scala的性能是不错的，如果优化JVM的话，scala可以大部分提高性能，但是scala性能分布并不一致，其中的一个点甚至到了最右边。就语言复杂性(Y轴)来说，scala的表现也不错，不过有时候为了获得高性能，也会导致语言复杂提高，比如scala的其中一个点就在最顶端。</p>
<p><a rel="attachment wp-att-974" href="https://coolshell.cn/?attachment_id=974"><img decoding="async" loading="lazy" class="aligncenter size-full wp-image-974" title="size-vs-speed-vs-depandability-scala" src="https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-scala.png" alt="size-vs-speed-vs-depandability-scala" width="329" height="358" srcset="https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-scala.png 329w, https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-scala-275x300.png 275w" sizes="(max-width: 329px) 100vw, 329px" /></a></p>
<p>通过为每一种语言形成如上的一个图，我们最后可以为这33种语言评的测结果形成了如下的一个图，这是一个6*6的图。其中每一个小图具有同样的轴和同样的精度。这张图的目的是为了方便的比较每一个语言的星型。这些图按语言的平均性能来组织列，最左边的语言的性能最好，最右边的语言性能最差，在每一列中的语言又按照平均的语言代码量(复杂程度)进行排列，代码量最小的语言在最低端，代码量最大的在最顶端。</p>
<figure id="attachment_975" aria-describedby="caption-attachment-975" style="width: 275px" class="wp-caption aligncenter"><a title="点击看大图" href="https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-2009.png"><img decoding="async" loading="lazy" class="size-medium wp-image-975" title="size-vs-speed-vs-depandability-2009" src="https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-2009-275x300.png" alt="size-vs-speed-vs-depandability-2009" width="275" height="300" srcset="https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-2009-275x300.png 275w, https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-2009-940x1024.png 940w, https://coolshell.cn/wp-content/uploads/2009/06/size-vs-speed-vs-depandability-2009.png 1221w" sizes="(max-width: 275px) 100vw, 275px" /></a><figcaption id="caption-attachment-975" class="wp-caption-text">点击看大图</figcaption></figure>
<p>在图的最左边的性能是最好的，又高又瘦的星型，我们可以看到，除了GCC和G++外，其他的性能都显示了惊人的一致性(每一个基准测试程序的性能都非常接近)。而JAVA也非常骄傲的出现在一组中，这说明经过了10年的优化后，Java运行时的性能已经得到长足的提高(要用Java做大系统的人是否还会犹豫呢：）)。<br />
在图的右边，我们看到了一些又胖又矮的星型，这些是一些脚本语言，从图中可以看出，这些脚本语言社区的人们当他们在不断改善他们语言的表达性的同时并没有花大力气在性能的改善上。然而也有例外，Lua这门脚本语言就有很好的执行性能。<!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-150x150.png" alt="编程语言流行度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_title">编程语言流行度</a></li><li ><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution-150x150.jpg" alt="编程语言进化" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_title">编程语言进化</a></li><li ><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-150x150.jpg" alt="计算机编程简史图" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_title">计算机编程简史图</a></li><li ><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/22.jpg" alt="五个编程语言设计的失误" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_title">五个编程语言设计的失误</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/973.html">编程语言的评测</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/973.html/feed</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
		<item>
		<title>编程语言流行度排名</title>
		<link>https://coolshell.cn/articles/706.html</link>
					<comments>https://coolshell.cn/articles/706.html#comments</comments>
		
		<dc:creator><![CDATA[陈皓]]></dc:creator>
		<pubDate>Tue, 28 Apr 2009 09:44:49 +0000</pubDate>
				<category><![CDATA[技术读物]]></category>
		<category><![CDATA[编程语言]]></category>
		<category><![CDATA[programming language]]></category>
		<guid isPermaLink="false">http://coolshell.cn/?p=706</guid>

					<description><![CDATA[<p>下面的这些排名并不是非常科学的，它们只是从某种方面表现出了编程语言的流行程度。仅供参考。 Yahoo Search 这里，我们使用了Yahoo Search A...</p>
<p class="read-more"><a class="btn btn-default" href="https://coolshell.cn/articles/706.html"> Read More<span class="screen-reader-text">  Read More</span></a></p>
The post <a href="https://coolshell.cn/articles/706.html">编程语言流行度排名</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></description>
										<content:encoded><![CDATA[<p><script async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js?client=ca-pub-3415450859608158"
     crossorigin="anonymous"></script>下面的这些排名并不是非常科学的，它们只是从某种方面表现出了编程语言的流行程度。仅供参考。</p>
<p><script src="http://www.langpop.com/javascripts/chartr.js" type="text/javascript"></script><br />
<strong>Yahoo Search</strong><br />
这里，我们使用了Yahoo Search API，简单地搜索了一下相关的编程语言。收搜字样是&#8221;language programming&#8221;，下面是搜索到的页面结果。也许这能够说明语言的流行程度。 </p>
<div id="search_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
      Flotr.draw($('search_results'), [[[33100.0, 1], [96800.0, 2], [105000.0, 3], [107000.0, 4], [109000.0, 5], [122000.0, 6], [287000.0, 7], [318000.0, 8], [339000.0, 9], [347000.0, 10], [357000.0, 11], [385000.0, 12], [397000.0, 13], [479000.0, 14], [678000.0, 15], [1900000.0, 16], [2000000.0, 17], [2210000.0, 18], [2250000.0, 19], [2430000.0, 20], [2530000.0, 21], [3340000.0, 22], [3360000.0, 23], [3430000.0, 24], [4730000.0, 25], [7350000.0, 26], [7350000.0, 27], [15500000.0, 28], [16900000.0, 29]]], {"yaxis": {"ticks": [[1.4, "OCaml"], [2.4, "Haskell"], [3.4, "Erlang"], [4.4, "Smalltalk"], [5.4, "Forth"], [6.4, "Tcl"], [7.4, "Ada"], [8.4, "Scheme"], [9.4, "Fortran"], [10.4, "Actionscript"], [11.4, "Lisp"], [12.4, "Cobol"], [13.4, "Lua"], [14.4, "Assembly"], [15.4, "Pascal"], [16.4, "SQL"], [17.4, "Shell"], [18.4, "Ruby"], [19.4, "Delphi"], [20.4, "D"], [21.4, "C#"], [22.4, "JavaScript"], [23.4, "Perl"], [24.4, "Python"], [25.4, "Visual\u0026nbsp;Basic"], [26.4, "C++"], [27.4, "PHP"], [28.4, "Java"], [29.4, "C"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><span id="more-706"></span></p>
<p><strong>工作相关</strong><br />
接下来，我们来看看与工作相关的页面。也是从Yahoo Search API中从Craigslist.org网站中取得这些数据。搜索模型如下：language programmer -&#8220;job wanted&#8221; site:craigslist.org。这个结果可以看到全球的雇主在雇佣技术人员的时候所要求的编程语言的数量分布。</p>
<div id="craigslist_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
      Flotr.draw($('craigslist_results'), [[[0.0, 1], [1.0, 2], [1.0, 3], [3.0, 4], [4.0, 5], [4.0, 6], [7.0, 7], [9.0, 8], [10.0, 9], [10.0, 10], [14.0, 11], [14.0, 12], [15.0, 13], [65.0, 14], [127.0, 15], [148.0, 16], [220.0, 17], [268.0, 18], [280.0, 19], [311.0, 20], [406.0, 21], [476.0, 22], [723.0, 23], [913.0, 24], [1110.0, 25], [1380.0, 26], [1760.0, 27], [1820.0, 28], [2210.0, 29]]], {"yaxis": {"ticks": [[1.4, "D"], [2.4, "Haskell"], [3.4, "OCaml"], [4.4, "Smalltalk"], [5.4, "Erlang"], [6.4, "Tcl"], [7.4, "Lua"], [8.4, "Lisp"], [9.4, "Fortran"], [10.4, "Scheme"], [11.4, "Ada"], [12.4, "Forth"], [13.4, "Pascal"], [14.4, "Delphi"], [15.4, "Cobol"], [16.4, "Shell"], [17.4, "Assembly"], [18.4, "Visual\u0026nbsp;Basic"], [19.4, "Python"], [20.4, "Ruby"], [21.4, "Perl"], [22.4, "Actionscript"], [23.4, "C++"], [24.4, "C#"], [25.4, "JavaScript"], [26.4, "Java"], [27.4, "C"], [28.4, "SQL"], [29.4, "PHP"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><strong>技术书籍</strong><br />
下面是由Amason所提供的搜索API中得到的目前出版物中的编程语言相关的统计数据，一般来说，越流行的语言通常会有更多的书籍。我们来看看书籍方面的各语言的书籍数量的排行榜。</p>
<div id="amazon_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
      Flotr.draw($('amazon_results'), [[[0.0, 1], [2.0, 2], [12.0, 3], [17.0, 4], [49.0, 5], [74.0, 6], [93.0, 7], [125.0, 8], [133.0, 9], [136.0, 10], [147.0, 11], [181.0, 12], [188.0, 13], [227.0, 14], [375.0, 15], [405.0, 16], [700.0, 17], [727.0, 18], [744.0, 19], [847.0, 20], [907.0, 21], [925.0, 22], [949.0, 23], [1192.0, 24], [1452.0, 25], [2317.0, 26], [2666.0, 27], [3694.0, 28], [7443.0, 29]]], {"yaxis": {"ticks": [[1.4, "D"], [2.4, "OCaml"], [3.4, "Erlang"], [4.4, "Lua"], [5.4, "Haskell"], [6.4, "Forth"], [7.4, "Smalltalk"], [8.4, "Actionscript"], [9.4, "Scheme"], [10.4, "Shell"], [11.4, "Ruby"], [12.4, "Delphi"], [13.4, "Python"], [14.4, "Lisp"], [15.4, "PHP"], [16.4, "Ada"], [17.4, "Perl"], [18.4, "Cobol"], [19.4, "Assembly"], [20.4, "JavaScript"], [21.4, "Fortran"], [22.4, "C#"], [23.4, "Tcl"], [24.4, "Pascal"], [25.4, "SQL"], [26.4, "C++"], [27.4, "Visual\u0026nbsp;Basic"], [28.4, "Java"], [29.4, "C"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><strong>Google Code 开源项目</strong><br />
下面的结果取自Googel Code (http://www.google.com/codesearch)，我们通过统计开源项目所使用的语言来查看是哪种语言在开源项目中的流行程度。</p>
<div id="googlecode_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
    Flotr.draw($('googlecode_results'), [[[4000.0, 1], [9000.0, 2], [44600.0, 3], [47600.0, 4], [87200.0, 5], [91100.0, 6], [154000.0, 7], [157000.0, 8], [173000.0, 9], [202000.0, 10], [219000.0, 11], [295000.0, 12], [296000.0, 13], [359000.0, 14], [363000.0, 15], [370000.0, 16], [422000.0, 17], [429000.0, 18], [429000.0, 19], [567000.0, 20], [865000.0, 21], [1070000.0, 22], [1490000.0, 23], [1730000.0, 24], [1800000.0, 25], [3680000.0, 26], [8400000.0, 27], [9800000.0, 28], [11300000.0, 29]]], {"yaxis": {"ticks": [[1.4, "Forth"], [2.4, "Cobol"], [3.4, "D"], [4.4, "Erlang"], [5.4, "Haskell"], [6.4, "Ada"], [7.4, "OCaml"], [8.4, "Lua"], [9.4, "Scheme"], [10.4, "Tcl"], [11.4, "Actionscript"], [12.4, "Lisp"], [13.4, "Visual\u0026nbsp;Basic"], [14.4, "SQL"], [15.4, "Assembly"], [16.4, "Fortran"], [17.4, "Smalltalk"], [18.4, "Delphi"], [19.4, "Pascal"], [20.4, "JavaScript"], [21.4, "Ruby"], [22.4, "Shell"], [23.4, "Python"], [24.4, "C#"], [25.4, "Perl"], [26.4, "PHP"], [27.4, "C++"], [28.4, "Java"], [29.4, "C"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><strong>Del.icio.us</strong><br />
del.icio.us是一个网摘网站，它提供的是一种收藏、分类、排序、分享互联网信息资源的方式。使用它存储网址和相关信息列表，使用标签(Tag)对网址进行索引使网址资源有序分类和索引，使网址及相关信息的社会性分享成为可能，在分享的人为参与的过程中网址的价值被给予评估。我们来看看BLOG社区中语言流行的程度。</p>
<div id="delicious_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
    Flotr.draw($('delicious_results'), [[[819.0, 1], [1405.0, 2], [2149.0, 3], [2835.0, 4], [2853.0, 5], [3044.0, 6], [3346.0, 7], [6041.0, 8], [6209.0, 9], [7840.0, 10], [8302.0, 11], [10009.0, 12], [11621.0, 13], [20318.0, 14], [26444.0, 15], [29016.0, 16], [31006.0, 17], [43919.0, 18], [51868.0, 19], [66527.0, 20], [71562.0, 21], [252024.0, 22], [252235.0, 23], [270101.0, 24], [270102.0, 25], [270102.0, 26], [283579.0, 27], [371783.0, 28], [428578.0, 29]]], {"yaxis": {"ticks": [[1.4, "Cobol"], [2.4, "Ada"], [3.4, "Pascal"], [4.4, "Tcl"], [5.4, "Fortran"], [6.4, "D"], [7.4, "Forth"], [8.4, "Lua"], [9.4, "OCaml"], [10.4, "Delphi"], [11.4, "Visual\u0026nbsp;Basic"], [12.4, "Assembly"], [13.4, "Smalltalk"], [14.4, "Erlang"], [15.4, "Scheme"], [16.4, "Shell"], [17.4, "Haskell"], [18.4, "Actionscript"], [19.4, "SQL"], [20.4, "Lisp"], [21.4, "Perl"], [22.4, "Ruby"], [23.4, "PHP"], [24.4, "C++"], [25.4, "C"], [26.4, "C#"], [27.4, "Python"], [28.4, "Java"], [29.4, "JavaScript"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><strong>Ohloh 开源项目</strong></p>
<p>让我们再来看一下<a href="http://www.ohloh.net/">Ohloh</a> 上的开源项目所使用的编程语言的统计图。</p>
<div id="ohloh_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
    Flotr.draw($('ohloh_results'), [[[0.0, 1], [0.0, 2], [254.0, 3], [287.0, 4], [333.0, 5], [402.0, 6], [585.0, 7], [618.0, 8], [981.0, 9], [1006.0, 10], [1092.0, 11], [1139.0, 12], [1139.0, 13], [1187.0, 14], [1502.0, 15], [1611.0, 16], [1813.0, 17], [3893.0, 18], [5213.0, 19], [5639.0, 20], [9612.0, 21], [14432.0, 22], [14523.0, 23], [16064.0, 24], [20234.0, 25], [24249.0, 26], [26223.0, 27], [26832.0, 28], [37028.0, 29]]], {"yaxis": {"ticks": [[1.4, "Cobol"], [2.4, "Forth"], [3.4, "Smalltalk"], [4.4, "Erlang"], [5.4, "Ada"], [6.4, "OCaml"], [7.4, "Fortran"], [8.4, "Lisp"], [9.4, "Haskell"], [10.4, "Visual\u0026nbsp;Basic"], [11.4, "D"], [12.4, "Pascal"], [13.4, "Delphi"], [14.4, "Scheme"], [15.4, "Actionscript"], [16.4, "Tcl"], [17.4, "Lua"], [18.4, "Assembly"], [19.4, "C#"], [20.4, "Ruby"], [21.4, "SQL"], [22.4, "PHP"], [23.4, "Perl"], [24.4, "Python"], [25.4, "JavaScript"], [26.4, "Java"], [27.4, "C++"], [28.4, "Shell"], [29.4, "C"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><strong>programming.reddit.com</strong><br />
我们再来看看聚合网站programming.reddit.com上的编程语言文章统计情况。</p>
<div id="reddit_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
    Flotr.draw($('reddit_results'), [[[0.0, 1], [0.0, 2], [0.0, 3], [0.0, 4], [0.0, 5], [0.0, 6], [0.0, 7], [1.0, 8], [2.0, 9], [3.0, 10], [3.0, 11], [4.0, 12], [5.0, 13], [11.0, 14], [11.0, 15], [14.0, 16], [21.0, 17], [22.0, 18], [24.0, 19], [28.0, 20], [31.0, 21], [33.0, 22], [38.0, 23], [67.0, 24], [70.0, 25], [72.0, 26], [93.0, 27], [108.0, 28], [115.0, 29]]], {"yaxis": {"ticks": [[1.4, "Actionscript"], [2.4, "Ada"], [3.4, "D"], [4.4, "Delphi"], [5.4, "Fortran"], [6.4, "Lua"], [7.4, "Visual\u0026nbsp;Basic"], [8.4, "Pascal"], [9.4, "Cobol"], [10.4, "Assembly"], [11.4, "SQL"], [12.4, "Forth"], [13.4, "Tcl"], [14.4, "OCaml"], [15.4, "Shell"], [16.4, "C#"], [17.4, "Smalltalk"], [18.4, "Scheme"], [19.4, "PHP"], [20.4, "Perl"], [21.4, "JavaScript"], [22.4, "Erlang"], [23.4, "C++"], [24.4, "Java"], [25.4, "Ruby"], [26.4, "Haskell"], [27.4, "Lisp"], [28.4, "C"], [29.4, "Python"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><strong>Slashdot</strong><br />
我们来看看Slashdot.org上的编程语言的排名情况吧。还是主要根据相关的贴子的数量做统计。</p>
<div id="slashdot_results" style="width:600px;height:350px">　　</div>
<p><script type="text/javascript"><!--
    Flotr.draw($('slashdot_results'), [[[0.0, 1], [1.0, 2], [2.0, 3], [3.0, 4], [3.0, 5], [3.0, 6], [4.0, 7], [4.0, 8], [4.0, 9], [6.0, 10], [7.0, 11], [7.0, 12], [9.0, 13], [10.0, 14], [12.0, 15], [15.0, 16], [16.0, 17], [25.0, 18], [30.0, 19], [43.0, 20], [45.0, 21], [49.0, 22], [55.0, 23], [56.0, 24], [56.0, 25], [76.0, 26], [78.0, 27], [128.0, 28], [166.0, 29]]], {"yaxis": {"ticks": [[1.4, "OCaml"], [2.4, "Haskell"], [3.4, "Tcl"], [4.4, "Actionscript"], [5.4, "Smalltalk"], [6.4, "Delphi"], [7.4, "D"], [8.4, "Lua"], [9.4, "Erlang"], [10.4, "Ada"], [11.4, "Fortran"], [12.4, "Pascal"], [13.4, "Forth"], [14.4, "Cobol"], [15.4, "Assembly"], [16.4, "C#"], [17.4, "Lisp"], [18.4, "Visual\u0026nbsp;Basic"], [19.4, "Scheme"], [20.4, "Shell"], [21.4, "SQL"], [22.4, "C++"], [23.4, "Ruby"], [24.4, "JavaScript"], [25.4, "Python"], [26.4, "PHP"], [27.4, "Perl"], [28.4, "C"], [29.4, "Java"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});
// --></script></p>
<p><strong>IRC</strong><br />
这里的数据来源于<a href="http://freenode.net/">Freenode</a> <a href="http://en.wikipedia.org/wiki/IRC">IRC</a>网络。</p>
<div id="irc_results" style="width:600px;height:350px">　　</div>
<p>  <script type="text/javascript"><!--
    Flotr.draw($('irc_results'), [[[1.0, 1], [3.82916666666667, 2], [4.18333333333333, 3], [6.29583333333333, 4], [9.37083333333333, 5], [9.68879668049792, 6], [18.5082644628099, 7], [19.8416666666667, 8], [20.4, 9], [34.8375, 10], [43.9709543568465, 11], [46.5714285714286, 12], [63.0416666666667, 13], [80.9833333333333, 14], [83.0916666666667, 15], [85.9834710743802, 16], [157.504166666667, 17], [159.6875, 18], [176.933333333333, 19], [185.425, 20], [230.8875, 21], [245.607438016529, 22], [248.216666666667, 23], [257.734439834025, 24], [281.399141630901, 25], [311.260330578512, 26], [348.575, 27], [371.645833333333, 28]]], {"yaxis": {"ticks": [[1.4, "Cobol"], [2.4, "Pascal"], [3.4, "Delphi"], [4.4, "Fortran"], [5.4, "Visual\u0026nbsp;Basic"], [6.4, "Actionscript"], [7.4, "Smalltalk"], [8.4, "Forth"], [9.4, "Ada"], [10.4, "Tcl"], [11.4, "Assembly"], [12.4, "OCaml"], [13.4, "Lua"], [14.4, "Scheme"], [15.4, "Erlang"], [16.4, "SQL"], [17.4, "JavaScript"], [18.4, "Lisp"], [19.4, "Ruby"], [20.4, "Shell"], [21.4, "Perl"], [22.4, "C#"], [23.4, "Haskell"], [24.4, "C"], [25.4, "C++"], [26.4, "Java"], [27.4, "PHP"], [28.4, "Python"]]}, "bars": {"horizontal": true, "show": true, "barWidth": 0.8}});  
//--></script></p>
<p>最后，如果你对其中的某些语言不是很熟悉的话，下面是维基百科上关于这些语言的链接。</p>
<li><a href="http://en.wikipedia.org/wiki/Actionscript">Actionscript</a></li>
<li><a href="http://en.wikipedia.org/wiki/Ada_(programming_language)">Ada</a></li>
<li><a href="http://en.wikipedia.org/wiki/Assembly_language">Assembly</a></li>
<li><a href="http://en.wikipedia.org/wiki/C_(programming_language)">C</a></li>
<li><a href="http://en.wikipedia.org/wiki/C_Sharp_(programming_language)">C#</a></li>
<li><a href="http://en.wikipedia.org/wiki/C%2B%2B">C++</a></li>
<li><a href="http://en.wikipedia.org/wiki/Cobol">Cobol</a></li>
<li><a href="http://en.wikipedia.org/wiki/D_(programming_language)">D</a></li>
<li><a href="http://en.wikipedia.org/wiki/Delphi_programming_language">Delphi</a></li>
<li><a href="http://en.wikipedia.org/wiki/Erlang_(programming_language)">Erlang</a></li>
<li><a href="http://en.wikipedia.org/wiki/Forth_(programming_language)">Forth</a></li>
<li><a href="http://en.wikipedia.org/wiki/Fortran">Fortran</a></li>
<li><a href="http://en.wikipedia.org/wiki/Haskell_(programming_language)">Haskell</a></li>
<li><a href="http://en.wikipedia.org/wiki/Java_(programming_language)">Java</a></li>
<li><a href="http://en.wikipedia.org/wiki/JavaScript">JavaScript</a></li>
<li><a href="http://en.wikipedia.org/wiki/Lisp_(programming_language)">Lisp</a></li>
<li><a href="http://en.wikipedia.org/wiki/Lua_(programming_language)">Lua</a></li>
<li><a href="http://en.wikipedia.org/wiki/OCaml">OCaml</a></li>
<li><a href="http://en.wikipedia.org/wiki/PHP">PHP</a></li>
<li><a href="http://en.wikipedia.org/wiki/Pascal_(programming_language)">Pascal</a></li>
<li><a href="http://en.wikipedia.org/wiki/Perl">Perl</a></li>
<li><a href="http://en.wikipedia.org/wiki/Python_(programming_language)">Python</a></li>
<li><a href="http://en.wikipedia.org/wiki/Ruby_(programming_language)">Ruby</a></li>
<li><a href="http://en.wikipedia.org/wiki/SQL">SQL</a></li>
<li><a href="http://en.wikipedia.org/wiki/Scheme_(programming_language)">Scheme</a></li>
<li><a href="http://en.wikipedia.org/wiki/Bourne_shell">Shell</a></li>
<li><a href="http://en.wikipedia.org/wiki/Smalltalk">Smalltalk</a></li>
<li><a href="http://en.wikipedia.org/wiki/Tcl">Tcl</a></li>
<li><a href="http://en.wikipedia.org/wiki/Visual%20Basic">Visual Basic</a></li>
<p><!--



<p align="center"><a href= target=_blank><img decoding="async" src=""></a></p>





<p align="center"><img decoding="async" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.weixin.jpg"> <img decoding="async" loading="lazy" src="https://coolshell.cn/wp-content/uploads/2020/03/coolshell.mini_.jpg" width="300" height="300"> <br />关注CoolShell微信公众账号和微信小程序</p>

 

--></p>
<div style="margin-top: 15px; font-size: 16px;color: #cc0000;">
<p align="center"><strong>（转载本站文章请注明作者和出处 <a href="https://coolshell.cn/">酷 壳 &#8211; CoolShell</a> ，请勿用于任何商业用途）</strong></p>
</div>

<div class="wp_rp_wrap  wp_rp_vertical_m" ><div class="wp_rp_content"><h3 class="related_post_title">相关文章</h3><ul class="related_post wp_rp"><li ><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2012/02/programming-language-150x150.jpg" alt="千万别惹程序员 " width="150" height="150" /></a><a href="https://coolshell.cn/articles/6639.html" class="wp_rp_title">千万别惹程序员 </a></li><li ><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/14.jpg" alt="读书笔记：对线程模型的批评" width="150" height="150" /></a><a href="https://coolshell.cn/articles/4626.html" class="wp_rp_title">读书笔记：对线程模型的批评</a></li><li ><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/12/rank_scatter1-150x150.png" alt="编程语言流行度" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3385.html" class="wp_rp_title">编程语言流行度</a></li><li ><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/10/language-evolution-150x150.jpg" alt="编程语言进化" width="150" height="150" /></a><a href="https://coolshell.cn/articles/3100.html" class="wp_rp_title">编程语言进化</a></li><li ><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/uploads/2010/07/aboutprogramming04.eng_-150x150.jpg" alt="计算机编程简史图" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2724.html" class="wp_rp_title">计算机编程简史图</a></li><li ><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_thumbnail"><img src="https://coolshell.cn/wp-content/plugins/wordpress-23-related-posts-plugin/static/thumbs/22.jpg" alt="五个编程语言设计的失误" width="150" height="150" /></a><a href="https://coolshell.cn/articles/2598.html" class="wp_rp_title">五个编程语言设计的失误</a></li></ul></div></div>The post <a href="https://coolshell.cn/articles/706.html">编程语言流行度排名</a> first appeared on <a href="https://coolshell.cn">酷 壳 - CoolShell</a>.]]></content:encoded>
					
					<wfw:commentRss>https://coolshell.cn/articles/706.html/feed</wfw:commentRss>
			<slash:comments>3</slash:comments>
		
		
			</item>
	</channel>
</rss>
