Share E-Book
Scan to open this page

Scan with your phone to open this page

AuthorPeter Cooper

Learn the principles behind object-oriented programming and within a few chapters create a fully functional Ruby application. Youll also gain a basic understanding of many ancillary technologies such as databases, XML, web frameworks, and networking - some of which are needed as part of a fully functioning Ruby application. The new edition of this book provides the same excellent introduction to Ruby as the previous editions plus updates for the newest version of Ruby 2.3. This book can also be used as a textbook or companion to a textbook on beginning Ruby programming. The light and agile Ruby programming language remains a very popular open source scripting option for developers building todays web and even some enterprise applications. And, now, Ruby also has applications using the Raspberry Pi, popular among hobbyists and makers. Many former Java developers still use Ruby on Rails today, the most popular framework for building Ruby applications. написал: (16 июля 2016 22:23)

AI Reading Assistant

Whole-book reading guide from stratified index samples; jump to passages in the text

AI guide
【One-Line Pitch】 A practical, project-driven introduction to Ruby 2.3 that takes you from installing the language to building complete applications, ideal for absolute beginners and programmers from other languages (especially Java) who want a fast, enjoyable path into object-oriented scripting and the Ruby ecosystem. 【Book Arc】 - **Opening (~0%–10%)**: Covers installation on macOS, Linux, and other platforms, plus a philosophical introduction to why Ruby is "English for computers." This stage solves the setup problem and sets the tone for a beginner-friendly, joy-focused learning experience. - **Early (~10%–30%)**: A whistle-stop tour of object orientation, then a deep dive into Ruby's building blocks—numbers, variables, strings, arrays, hashes, flow control (if/unless/case/while), code blocks, dates, ranges, and symbols. This is the core syntax foundation that everything else builds on. - **Early (~30%–37%)**: The first hands-on project: building a text analyzer that loads files and counts lines, characters, words, sentences, and paragraphs. This stage transitions from theory to practice, showing how to structure and run a real source code file. - **Early (~37%–40%)**: An ecosystem overview covering alternative Ruby implementations, Ruby on Rails' origins, open-source culture, and where to find help (mailing lists, IRC, forums). This contextualizes Ruby within the broader developer community. - **Middle (~40%–50%)**: Part 2 begins with the core of Ruby: classes, objects, modules, inheritance, encapsulation, polymorphism, and reflection. Then it moves to projects and libraries (RubyGems, Bundler), and finally documentation, error handling, debugging, and testing—including test-driven development philosophy and benchmarking. - **Middle (~50%–end of excerpts)**: The guide's excerpts end mid-chapter on benchmarking and profiling, but the table of contents shows the book continues into files/databases, distributing code, advanced features, and a larger capstone application, followed by a "Ruby Online" part. 【Key Takeaways】 - **Object orientation is the heart of Ruby** (Early): Everything is an object, and the book teaches this through relatable examples like modeling people and pets. This mental model is essential for reading and writing idiomatic Ruby. - **Interactive learning with irb accelerates comprehension** (Early): The book encourages experimenting in the Interactive Ruby shell from the start, making it safe to test expressions and methods immediately. This hands-on loop is the fastest way to internalize syntax. - **Flow control and data structures are the practical toolkit** (Early): Mastery of if/unless, case, while/until, arrays, hashes, and code blocks lets you solve most everyday scripting problems. The book pairs each concept with concrete examples, not abstract theory. - **The first project cements fundamentals** (Early): Building a text analyzer forces you to combine file I/O, string methods, and counting logic into a working program. This is the pivotal moment where syntax becomes skill. - **The Ruby ecosystem is part of the language** (Early): Knowing about RubyGems, Bundler, and Rails helps you place Ruby in the real world. The book explains not just how to code, but how to find libraries and community support. - **Testing and debugging are professional habits, not afterthoughts** (Middle): The book introduces RDoc for documentation, exceptions for error handling, the Ruby debugger, and Minitest for unit testing. It also frames test-driven development as a philosophy, not just a tool. - **Performance awareness comes early** (Middle): Benchmarking and profiling are introduced as standard practices, showing that even beginners should care about how their code runs. This sets a professional mindset from the start. 【Reading Tips】 - **Skim the installation chapters if you're on a common platform** (Early): The macOS/Linux setup is straightforward; focus instead on Chapter 2's object-orientation tour, which is conceptually dense and worth reading twice. - **Deep-read Chapter 3 on building blocks**: This is the longest and most important syntax chapter. Work through every example in irb, especially code blocks and iterators, as they are Ruby's signature feature. - **Do the text analyzer project in Chapter 4 fully**: Don't just read it—type it out, break it, and fix it. This is where the book's "novice to professional" promise starts to pay off. - **Treat Part 2 as a reference to revisit**: Chapters on classes, modules, and testing are rich but can be skimmed first, then returned to when you need specific details for your own projects. - **Skip the ecosystem chapter if you're already a developer**: Chapter 5's community and Rails history is useful context but not essential for coding; you can return to it later. 【Coverage Limits】 The excerpts cover roughly the first half of the book (through benchmarking/profiling in Chapter 8). Chapters on files/databases, advanced features, and the final larger application are not covered in this guide.
Page 3
or dissimilar methodology now known or hereafter developed. Exempted from this legal reservation are brief excerpts in connection with reviews or scholarly a...
View in text
Page 6
macOS ................................................................................................................................. 6 Linux ................
View in text
Page 6
81 Counting Sentences and Paragraphs ................................................................................................... 82 Calculating Avera...
View in text
Page 6
Other Directories ....................................................................................................... 151 Logic and Including Code .........
View in text
Page 14
............................................................... 238 Summary ....................................................................................
View in text
Page 16
............................................................ 305 The Limitations and Benefi ts of Our Approach .................................................
View in text
Page 6
.......................................................................................................................................... 391 Examples ........
View in text
Page 20
................................................................................................................... 410 Installation ...........................
View in text
Tags
AI categories
ProgrammingTechnologyEducation
ISBN: 1484212797
Publisher: Apress
Publish Year: 2016
Language: English
Pages: 585
File Format: PDF
File Size: 13.8 MB
Text Preview (First 20 pages)
Registered users can read the full content for free

Register as a Gaohf Library member to read the complete e-book online for free and enjoy a better reading experience.

Generating text preview…