Ruby has gained some attention through the popular Ruby on Rails web development framework, but the language alone is worthy of more consideration -- a lot more. This book offers a definition explanation of this powerful and extremely flexible language, which draws inspiration from Lisp, Smalltalk and Perl, but uses a grammar that's easy for C and Java programmers to learn.
With The Ruby Programming Language, you will quickly learn your way around versions 1.8 and 1.9, and discover why this pure object-oriented language is also suitable for procedural and functional programming styles. You'll learn Ruby's lexical structure, primary expressions, conditionals, syntax, classes, the data it manipulates, and more. Ruby blurs the distinction between language and platform, so this book includes a tour of the core Ruby API. But the primary subject is the language itself, including:
* Ruby's lexical structure including basic issues like character set, case sensitivity and reserved words
* Numbers, strings, ranges, arrays, and other data that Ruby programs can manipulate, plus basic features of all Ruby objects
* Primary expressions in Ruby -- literals, variable references, method invocations and assignments
* Conditionals, loops (including blocks and iterator methods), exceptions and other Ruby expressions
* Ruby's method definition and invocation syntax, and the invokeable objects known as procs and lambdas
* An explanation of closures in Ruby and an exploration of functional programming techniques
* Classes and modules in Ruby, inheritance, method visibility, mixing modules and the method name resolution algorithm
* Ruby APIs that allow a program to inspect and manipulate itself, and metaprogramming techniques that use the APIs to extend Ruby's syntax for easier programming
* A quick tutorial of the Ruby platform -- the most important classes and methods, text processing, numeric computation, collections, input/output, networking and threads
The Ruby Programming Language also covers the top-level Ruby programming environment, including global variables and functions, command-line arguments supported by the Ruby interpreter, and Ruby's security mechanism. If you're an experienced programmer who wants a look at this language in depth, this easy-to-follow guide is invaluable.
David Flanagan is a computer programmer who spends most of his time writing about JavaScript and Java. His books with O'Reilly include Java in a Nutshell, Java Examples in a Nutshell, Java Foundation Classes in a Nutshell, JavaScript: The Definitive Guide, and JavaScript Pocket Reference. David has a degree in computer science and engineering from the Massachusetts Institute of Technology. He lives with his wife and children in the U.S. Pacific Northwest bewteen the cities of Seattle, Washington and Vancouver, British Columbia. David has a blog at www.davidflanagan.com.
Yukihiro Matsumoto ("Matz"), the creator of Ruby, is a professional programmer who worked for the Japanese open source company, netlab.jp. Matz is also known as one of the open source evangelists in Japan. He's released several open source products, including cmail, the emacs-based mail user agent, written entirely in emacs lisp. Ruby is his first piece of software that has become known outside of Japan.
写的很不错,尤其是ruby语言的特点,比如实现yield段或者和Java非常不一样的unless,untile等等。推荐大家也去读读《代码之美》里面的“程序如散文”
评分首先这不算是入门书,作为入门书太枯燥难以理解。 其次这不算是进阶书,因为讲的都是关于ruby的语言特性。 这也不是cookbook。 所以我觉得把RPL比做ruby版K&R挺贴切的。虽然我们都跟人说K&R是入门经典,可自己个谁不是先看谭浩强或者其他随便什么21天绕弯路过来的。ruby入门首...
评分以前听说学编程的话,得买这本书来看下。不过书买到了自己一翻,根本看不懂啊!晕。成了鸡肋一样,不学扔了可惜;学呢又自己太吃力!也没空出去找培训班,而且就算找到,就学这一门课,哪有人教啊。到处搜索,后来找到一个“猎豹网校”,想学什么课程可以任选的,学一门也行的...
评分比Programming Ruby强不少,语法思路的极其清楚,框架堪称完备精美。这点上说有点像是中国人的风格。涵盖了1.9,现在也有影印版了。
评分第45页 “当一个表达式含有多个指数操作时,他们按照从右到左的顺序执行,因此4**3**3的值与4**9相同,而不同于64**2” 说实话这句里有两个错误 第一,4**3**3的值与4**9的并不相同,而应当与4**27相同 第二,4**3**3的值和64**2的值差的就更远了,只能说之笔误,原来打算写的...
这本书简直就是为我量身定做的!我一直对 Ruby 这种语言充满了好奇,但又觉得入门门槛有点高,总担心找不到一个既深入又易懂的教程。终于,当我翻开《The Ruby Programming Language》时,我悬着的心才算放了下来。作者以一种非常自然、循序渐进的方式,将 Ruby 的核心概念娓娓道来。我特别喜欢它讲解面向对象编程的部分,没有那些枯燥乏味的理论堆砌,而是通过生动形象的例子,让我一下子就理解了类、对象、继承、多态这些抽象的概念。而且,书中对 Ruby 简洁而优雅的语法风格的介绍,也让我对这门语言产生了更深厚的兴趣。不仅仅是基础知识,它还触及了一些更高级的主题,比如元编程和 DSL 的构建,这些内容虽然对我来说还有些挑战,但作者的解释让我看到了它们在实际开发中的巨大潜力。阅读这本书的过程,就像是在和一位经验丰富的导师进行一次愉快的对话,我能够轻松地跟上他的思路,并且在不知不觉中吸收了大量有价值的知识。
评分我是一名刚刚开始接触编程的绝对新手,选择《The Ruby Programming Language》作为我的第一本编程书,起初有些担心它是否会太难。《The Ruby Programming Language》的出现彻底打消了我的顾虑。它就像一位耐心的老师,一步一步地引导我进入编程的世界。书中从最基础的概念讲起,比如什么是变量、什么是函数,用非常通俗易懂的语言解释了这些概念,让我不会因为术语而感到困惑。即使是对于像条件语句和循环这样的逻辑控制,作者也通过一些生动有趣的小故事或小练习来加深我的理解。让我感到特别安心的是,书中总是在讲解完一个概念后,会立刻提供相应的代码示例,我可以在电脑上亲手尝试,看到代码运行的结果,这种即时反馈非常有成就感。而且,这本书的排版也相当友好,代码块清晰明了,注释也很到位,让我能够轻松地跟随。对于像我这样的初学者,这本书的引导作用是巨大的,它让我对编程产生了浓厚的兴趣,并且能够建立起正确的学习方法。
评分如果你正在寻找一本能够带你深入 Ruby 世界的宝典,那么《The Ruby Programming Language》绝对是你不可错过的选择。我之前尝试过几本 Ruby 的入门书籍,但总觉得它们要么过于肤浅,要么内容组织得不够清晰。《The Ruby Programming Language》则完全不同,它以一种极其严谨和系统的方式,为读者构建起一个扎实的 Ruby 知识体系。书中对 Ruby 语言的各个方面都有着详尽的阐述,从基本的数据类型、控制结构,到更复杂的模块、类的方法,甚至是 Ruby 的一些独特机制,都做了非常清晰的讲解。我印象深刻的是它对 Ruby 核心库的介绍,那些强大的内置方法和模块,在书中得到了充分的展示,让我感受到了 Ruby 语言的强大和灵活性。而且,书中还包含了一些实际应用的示例,这些示例不仅能够帮助我理解理论知识,更能让我看到 Ruby 在解决实际问题中的强大能力。这本书的深度和广度,让我觉得物超所值,它无疑为我的 Ruby 学习之路打下了坚实的基础。
评分对于任何想要深入理解 Ruby 语言的开发者而言,《The Ruby Programming Language》都是一本不可或缺的参考。我之前也阅读过一些 Ruby 的书籍,但很多都停留在表面,无法深入触及语言的精髓。《The Ruby Programming Language》则不同,它以一种更加宏观和深刻的视角,为读者揭示了 Ruby 语言的内在逻辑和设计哲学。书中对 Ruby 的元编程能力、块(blocks)以及 Proc/lambda 等高级特性的讲解,非常精彩,让我对 Ruby 的动态性和灵活性有了更深刻的认识。作者在处理这些复杂主题时,并没有回避它们的难度,而是通过精妙的解释和恰当的示例,将它们化繁为简,让读者能够理解其背后的原理和应用场景。我特别喜欢书中对 Ruby 生态系统的介绍,以及如何利用 Ruby 来构建 DSL(领域特定语言),这让我看到了 Ruby 强大的可扩展性和在不同领域应用的潜力。这本书的价值,不仅仅在于其技术内容的深度,更在于它能够帮助开发者构建出更优雅、更具表现力的 Ruby 代码。
评分作为一名资深的程序员,我阅书无数,但《The Ruby Programming Language》依旧给了我极大的惊喜。我原本以为自己对 Ruby 已经有所了解,但这本书还是向我展示了许多我之前未曾注意到的细节和深度。作者在解释 Ruby 的一些核心设计理念时,有着独到的见解,让我对这门语言有了全新的认识。书中对 Ruby 虚拟机、垃圾回收机制等底层原理的探讨,虽然不是初学者最关心的部分,但对于想深入理解 Ruby 性能和工作方式的开发者来说,这些内容具有极高的参考价值。我尤其欣赏书中对于 Ruby 哲学和最佳实践的介绍,这不仅仅是技术的讲解,更是编程思想的传递,让我能够写出更“Ruby”的代码。虽然这本书的篇幅不小,但我发现自己阅读起来非常流畅,因为作者的逻辑清晰,表达准确,并且总是能用恰当的例子来佐证观点。对于那些希望在 Ruby 领域有所建树的开发者来说,这本书绝对是必备的参考书。
评分很强大
评分简单,入门。大爱ruby,短码太漂亮,尤其是小规模工具类的应用,不用ruby就太对不起自己了。
评分基本读完了,讲的真的很细致, 很深刻,前后呼应的好, 对于元编程讲的不错,不足之处可能也是讲的太细了,让人易烦
评分看得累死orz
评分Beginner, also try learn ruby the hard way