"a seminal text on code reading."Thanks Sue!
For prospective readers of code whose base language is C, I can heartily recommend Diomidis Spinellis’ excellent book “Code Reading,” which delves deeply into OSS C codebases, and serves as a very effective guide to reading code and knowing what to look for. It is, to my knowledge, the only book written on the topic.
D. Spinellis did a great job putting this book together. This book is packed with examples, best practices and information that are useful to developers, project leads and managers. Now you can have all the experience of the open-source community, the people that developed Linux, Apache and other popular software applications, at the tip of your finger.
"For those of you who like code and love C (very related), this book will have you appreciating it even more. It stresses the joy of reading code for fun and education. Spinellis, D. Code Reading, Addison Wesley, 2003, 0-201-79940-5."If you decide to follow his advice, I'd recommend combining it with a box of chocolates. You can't go wrong with chocolates.
"I admire good writers, which is one a reason why I read so much. I've never read a novel by Stephen King - I find his plots to be silly - but I admire his passion and skill for writing, which he describes in On Writing (the only work by Stephen King I've read; in this work, by the way, he relates how writing saved him after his serious accident a few years ago). Norman Mailer's The Spooky Art, William Zinsser's On Writing Well, and Christopher Volger's The Writer's Journey are other good works. In the software space, there's Joel Spolsky's The Best Software Writing and Diomidis Spinellis' Code Reading."I'm amazed and honoured.
"I wanted to read Code Reading: The Open Source Perspective as soon as I heard about it. [...] The book is cleary written with good examples, thougtful exercises that require you to dig in, and a practice CD-ROM of open source projects. [...] The book would make a great textbook. You might not see it in an undergraduate class, but you should, because it offers so much valueble, introductory information."
"Overall, Code Reading: The Open Source Perspective is ambitious and worthwhile, both as a complement to a bookshelf of study that includes The Practice of Programming and Design Patterns, and to someone who is growing tired of books on learning a language."
"Code Reading is a book that will age very well. Little of it will be irrelevant in 10 years and most will still be relevant in 20. Sounds like the makings of a classic."
"About 20 years ago, Marc Donner pointed out to me the importance of reading code carefully. He later taught a course at NYU on code reading. Spinellis has turned out a fine book on Code Reading, accompanied by a CD full of source and examples. He makes the same point that Donner did: You will write better code if you make it a habit to read good code."
[...] [Code Reading] is a project or a map to mastery. It will leave readers inspired but also frustrated at how much there is to know before they are masters. Novice and journeyman programmers will find this to be the mother lode, a rich vein of pure ore to mine for mastery. Managers might consider buying this book for their programmers and making a commitment, encouraging them to acquire and learn the methods and tools featured in the text. [...]The review concludes:
This is a book that I hope will create a trend or perhaps a movement toward the development of a deep understanding of creative code mastery. All programmers (even those who are already masters) could benefit from having this book on their bookshelves. It is a tool they can use themselves or support their efforts to mentor others. It is time to begin teaching code reading as an enabling skill leading to programming mastery.
The book gives a good feel of how one should read source code. As a computer science student, the book emphasizes to the reader the importance of reading code to write better code yourself. It teaches you to look at the "forest instead of the trees." Included in the source is often very big real world programs, but the book teaches you how to isolate parts of the code that are relevant to what you are looking for. I consider this book to be a very valuable supplement to my instruction in class.
"I would recommend this book to any coder who's serious about their craft."
"I would recommend this book to anyone looking to become involved in the Open Source movement, as a good appreciation for the reading of code will be of immense value. Even more than that, I would recommend it to Computer Science students and professors, as it formalizes a skill that really ought to be taught in schools."
"Code Reading is a wonderful book, and an important one. It doesn't matter whether you're still in high school, or have been programming every day for the last 30 years-this book will teach you things you really need to know. More importantly, I think this book just might change the way programming is taught and learned."
"From what Greg [Wilson] can tell, Code Reading: The Open Source Perspective, by Diomidis Spinellis, is an important book that every programmer should read." The actual review ends: [the book] "could do more to change our profession for the better than any of the bandwagons that have rolled by in the last 20 years".
"Spinellis challenges us to expand our minds as he leads us through examinations of several well-designed software systems. Reading others' code serves several useful purposes—if, as stats suggest, 80 percent of all programming is maintenance, we spend most of our time reworking existing code. Yet how many of us have learned—except through trial and error—a systematic method for understanding what others have written? Spinellis offers us effective techniques for doing so in C and Java, and we'd be well-advised to pay attention."
"Spinellis notes that the open-source movement has made available a great deal of excellent code. His book uses this resource to help you become a good code reader and writer. Using numerous examples from actual code, Spinellis discusses a wide variety of programming topics. In the end, he has written a computer science textbook with all of the examples taken from real life."
"Fact: If you make a habit of reading good code, you will write better code yourself."
In this book, the author covers one of the most important tasks faced by programmers every day: reading and understanding existing code. He thoroughly explains basic programming elements, project design as well as coding standards and conventions, concluding with a real life example of how to extend a given program by reading code from various sources and improving on it.
The vast majority of the code examples in the book are based on NetBSD source code (a snapshot of NetBSD 1.5_ALPHA is part of the software of the accompanying CD-ROM), because the NetBSD Project's emphasis on "correct design and well-written code" makes it "a superb choice for providing example source code."
More People Should Read This
so i just got my copy of code reading — the open source perspective in the mail today (i love amazon). it's fantastic. this kind of thing should be taught in computer science programs. maybe with books like this appearing, it will be.
Unique and innovative read
Reviewer: Jack D Herrington from Union City, CA United States
This is the most interesting technical read I have had since the release of Dave Thomas and Andrew Hunt's "Pragmatic Programmer". Which isn't suprising, given that Dave appears to have been involved with this book as well. The conveys book experience as opposed to raw information. He gives pragmatic advice that will benefit both junior and senior engineers in their day-to-day code and project development. I've become bored with the usually 'foo in three weeks' style books. If you are in the same position and you are interested in books about proven techniques and the pragmatic approach, this book is for you. The first few chapters had me questioning my purchase but the closing chapters removed any doubt that I had spent my money well. There were helpful hints that will save me minutes and hours throughout the work-week which means that I will be working smarter rather than harder. It was only through random chance that I saw this book in the Palo Alto Borders. Great books like these need solid marketing. That being said, I applaud Addison-Wesley in their investment in a book like this which is a little outside of the norm, but is an incredibly valuable work for the software engineering community.
He encontrado un libro que a buen seguro despertará el interés de una inmensa mayoría de lectores de BarraPunto. Se trata de Code Reading: The Open Source Perspective, escrito por Diomidis Spinellis. Tras leer el prólogo te sientes obligado a hacerte con una copia (aún no he recibido la mía, por lo que mi impresión se basa en la lectura del título, el prólogo y el índice). A través de ejemplos de código fuente bien escrito y también de mal código, extraido de programas escritos en C, C++ y Java procedentes de NetBSD, el libro pretende enseñar a leer código fuente, una actividad necesaria para reutilizar código o para realizar mejoras a código existente. Pero quizá lo que debería beneficiarse especialmente de la disponibilidad de millones de líneas de código fuente libre es la formación de ingenieros informáticos. Colocaremos este libro en la estantería de ingeniería de software libre, junto a The Practice of Programming, el segundo volumen de TCP/IP Illustrated, las Notes on the Plan 9 kernel source (.ps.gz) o el Lion's Commentary on UNIX 6th Edition. ¿Qué otros libros que conozcas añadirías a la estantería de ingeniería de software libre?
"Code Reading: The Open Source Perspective"
Handle Overwhelming Code Jobs, Demystify Tangled Code and More A new 528-page book titled, "Code Reading: The Open Source Perspective," aims to show readers how to read both good and bad code, what to look for and how to improve their own code. The book also discusses techniques for handling overwhelming code jobs, figuring out mystifying code and comprehending tangled programs. Author Diomidis Spinellis has been working with the techniques he writes about in this book since 1985. During that time he has written and maintained more than 250,000 lines of code for many commercial and open source projects. Spinellis is also a four-time winner of the International Obfuscated C Code Contest. He is currently an assistant professor in the Department of Management Science and Technology at the Athens University of Economics and Business. The book uses open source software to present a primer and reader for software code. It examines the background knowledge and techniques needed to read code written by others. Using more than 600 real-world examples, the book tries to cover most of the code-related concepts that a software developer is likely to come into contact with, including programming constructs, data types, data structures, control flow, project organization, coding standards, documentation and architectures. Many of the source code examples that the book uses come from the source distribution of NetBSD, a free, highly portable UNIXR-like operating system available for many platforms. NetBSD is considered an appropriate choice for both production and research environments because of its clean design and advanced features. The author chose the OS over similar kinds because NetBSD emphasizes correct design and well written code. The OS also avoids encumbering licenses, provides a portable system running on many hardware platforms, interoperates well with other systems and conforms to open systems standards as much as is practical. The other systems used in the book's examples are chosen for reasons of code quality, structure, design, utility, popularity and a flexible license. The author attempts to balance the selection of languages by selecting suitable JavaTM platform and C++ code.
If the topic of this book interests you, it belongs at the top of your list of to-be-read software books. The book is about what its title says - code reading. It is essentially a how-to book on learning to read software source code. The book opens with "As far as I know, this is the first [book] to exclusively deal with code reading." I'm fairly sure the author is right. Because of that, I recommend this book for the tool kit of all software practitioners, and for the study satchel of all software novices (to be replaced when a more novice-focused book becomes available). There are insights galore for programmers of all experience levels here!
(C) Copyright 2000-2011 D. Spinellis.
May be freely uploaded by WWW viewers and similar programs.
All other rights reserved.
Last modified: 2011-06-21 |