Hacker News new | past | comments | ask | show | jobs | submit login
The Art of Computer Programming - eBook (informit.com)
94 points by tjr on Dec 5, 2013 | hide | past | favorite | 65 comments



Knuth says:

For many years I've resisted temptations to put out a hasty electronic version of The Art of Computer Programming, because the samples sent to me were not well made.

But now, working together with experts at Mathematical Sciences Publishers, my publishers and I are launching an electronic edition that meets the highest standards. We've put special emphasis into making the search feature work well. Thousands of useful "clickable" cross-references are also provided --- from exercises to their answers and back, from the index to the text, from the text to important tables and figures, etc.

The first fascicle can now be ordered from Pearson's InformIT website, and we expect to release thousands of additional pages next year.

http://www-cs-faculty.stanford.edu/~knuth/news.html


I have the first 4 books, but reading that makes me want to get it as an e-book, as well.


>For many years I've resisted temptations to put out a hasty electronic version of The Art of Computer Programming, because the samples sent to me were not well made

Not well made? It's a book that is a PDF at some point before it hits printing presses. What is there to make at all? The kindle has been out for how many years? how is the book so different when reading it on an e-ink display? He mentions that shortcuts were added, but still - how is it worse than a printed book (there are no links there either).

This seems disingenuous.


PDFs and ebook readers are not a good mix. PDFs are designed to look the same on every device and on paper, and that doesn't work well when you've got bigger and smaller readers. A well-made ebook—something that's been made as an ebook—reflows well regardless of the form factor of the device (and there are many).

Also, most devices have zoom/text size capability, and PDFs don't play nicely with that, nor do they really work well with image placement on screen. When you bear in mind that a weighty technical tome like TAoCP has lots of equations, and equations use lots if images, it all gets pretty ugly when you're stuck with a fixed-form PDF.


I'm sure Knuth will be glad to know any customer can purchase TAoCP from Pearson/InformIT in any electronic format that he wants so long as it is PDF.

Additionally, Pearson/InformIT have chosen to enhance the layout of each page by discreetly reminding the reader of their full name.


> PDFs and ebook readers are not a good mix. I beg to differ. Maybe PDFs and small-screen eInk readers are not a good mix.

For anything technical (computer science/maths) I only buy an eBook if there's a PDF version available (a PDF that looks like the print edition). I've had nothing but bad experience with reflowable formats such as EPUB with technical books. Equations and graphs are stored as low resolution images, any complex layout (floats for example) has to be turned into a strictly linear flow, etc... A vector PDF, on the other hand, is infinitely scalable, so you can zoom in on graphs and equations without any loss of quality.


Still, all those arguments are moot, since the book released now is just a PDF.


Probably best not to argue with Donald Knuth about typesetting.


Well, an ebook experience is about much, much more than just typesetting. (See eg some comments in this discussion.)


Disingenuous? Maybe you're unaware of why Knuth invented TeX in the first place: https://en.wikipedia.org/wiki/TeX#History.

It sounds to me like Knuth wanted something that wasn't just a straight up text dump of his book. If you're going to bother exporting your book to an interactive format, it makes sense to do it in such a way that it takes advantage of that format.


Someone has not read many mathematical books on a Kindle (or even PDFs on an iPad), let alone seen the intricate typesetting of TAoCP. For an epub the configurable font size alone wreaks havoc with mathematical typesetting, and converting them to pixelated versions fails as screen resolutions go to higher and higher DPI.

It's a monster of a problem, which still isn't solved. As good as TeX/LaTeX is at handling paper sizes, the screen sizes / DPIs / pagination / font sizes of eReaders is a far more difficult platform to target.


Why is it disingenuous? Have you looked into the complexities of eBooks?

You have to not only figure out what format to release in, but also deal with various screen formats and linkages.

Sure you can release a version of the master file relying on the software's search feature and make your user deal with the formatting, but it will look bad in nearly every setting.

Note that this is especially true of ebooks which don't have responsive displays and need to be formated for to display as you would expect. You cannot simply throw a PDF with arbitrary dimensions and get good results.


>You cannot simply throw a PDF with arbitrary dimensions and get good results.

Yet, that is exactly what they did.

That's why it's disingenuous.


Wait, what? Well nevermind then, that sucks.


> It's a book that is a PDF at some point before it hits printing presses. What is there to make at all? The kindle has been out for how many years? how is the book so different when reading it on an e-ink display?

Just anecdotal information : my Kindle regularly reports the infamous "Low memory" error and closes down the book when I try to read my 8 MB copy of "Programming in Scala, 2nd Edition". It definitely detracts from the reading experience, especially knowing upfront that you can read only a few pages before you hit the dreaded error.

I suppose Knuth's book would be equally, or more, "heavy" and the Kindle would choke on the pdf versions.


Knuth loves his type-setting. He created TeX for crying out loud! I'm sure he detests what epub readers do to his works. And I'm sure he is no fan of how pdfs look on e-readers either.


If you truly believe what you wrote, you don't know Knuth.


Wait, I thought the whole point of this book was occupy space on my shelf in a highly visible area. Can they at least include a dust cover so I can subtly project my latent leetness?


I recently graduated with a degree in math but not much programming experience (I am pretty familiar with Mathematica but nothing else). I was thinking about picking up an intro to CS book to begin learning CS. Would this book be good for this? Should I even bother with CS theory or just jump into using a language?


To put it in math terms, using TAOCP for an intro to computer science would be like using Russell and Whitehead for an intro to arithmetic.


On the other hand, if you wanted to recreate modern Computer Science from scratch, without knowing it (e.g. all the programmers died from a zombie plague and you need to stop an alien invasion; or you're stuck on a desert island with a computer and lots of batteries and know that if you can program a new wireless radio driver you can put out enough interference to catch a plane's attention) and TAOCP was the only book that was accessible, it might be enough.


It depends on what you want. I've only read the first volume so far, but I would say that it's definitely appropriate for an intro to CS since you have the math background. I would definitely not recommend it to most people since the math is pretty dense and not all necessary (though very interesting). If you're familiar with combinatorics and stats, then it won't be too bad.

As a CS book, it teaches a lot of good CS concepts and techniques very thoroughly, and it analyzes the performance of algorithms very precisely. You'll not only use Big O notation, but you'll also figure out some of the constants. So, if your interest is in computer science proper, then this is a great introductory book.

On the other hand, if your goal is to be able to write programs, then definitely jump into using a language. Go find a book on a language and just start using the language to solve problems. After you get past the basics of programming, you'll start to see all the applications to math (especially discrete math). I've heard Structure and Interpretation of Computer Programs is a good book, and I plan to read it next semester, so maybe that's a good one for you. It uses Scheme (a Lisp) as the programming language, so the parallels with math are very clear.


As you said, it's dense. Enough so, that few people will read it cover to cover sequentially.

It's challenging, where "challenging" means that it requires living with some bewilderment and frustration while reading it. And anyone who is not as smart and knowledgeable as Knuth will probably experience both to some degree because what makes tAoCP great is that Knuth doesn't dumb anything down.

Over the years, I've found that tAoCP works well without having to dig deeper into the math [or MIX] than I am able or interested in diving...the abstractions are laid out well and understandable as abstractions without getting buried in algorithmic analysis...though the analysis can be interesting.

My take is that if someone is serious enough to try to tackle it, it will give back more than the effort put in regardless of the person's computer science background.


Read this: http://mitpress.mit.edu/sicp/full-text/book/book.html -- think most will agree with me.


These are HN favorites, along with K&R - I wouldn't recommend any of them to beginners no matter what their background is.

Instead I'd suggest a good succinct explanation of Big O notation to be digested and promptly forgotten (anybody who studied calculus should have intuition for it anyway, it just nicely ties in to the "cost" of the code they'll produce) and straight to scripting in Python with them. :)


K&R is not a good book to learn how to program from. SICP on the other hand is[1], it teaches how to create abstractions among other things. K&R just shows you how C works. Also, this person has a deep understanding in mathematics and should have no problems digesting an introductory book, such as SICP, at all.

[1] http://www.eecs.berkeley.edu/~bh/sicp.html


I really like Winston and Horn's Lisp. It actually is written assuming you don't know how to program at all, but quickly moves along into more complex stuff, really showing off what Lisp can do. Winston teaches (taught?) at MIT, and when the book was first written I guess it was still a reasonable possibility that you could be a freshman at MIT in computer science and have never programmed before.

http://www.amazon.com/Lisp-3rd-Edition-Patrick-Winston/dp/02...


Interesting book, thanks for the info! Will take a look.


As much as I love SICP I have to say that I think that its biggest power is showing a different way to view programming. Unless you already know the basics its hard to appreciate it.


PDF versions for computer and font/size adjusted version for e-book/tablet are here: http://sicpebook.wordpress.com/


> I was thinking about picking up an intro to CS book to begin learning CS. Would this book be good for this?

No, absolutely not.


Buy the Knuth book. You can get it used for ~$25 on Amazon, and if it gathers dust or you dislike it, sell it and buy something like Programming Collective Intelligence for some fun motivating problems and to learn Python.

In Knuth's book you learn about and work with the details of how computers work that Mathematica handles itself and explicitly hides from you. If you ever wondered, for example, how Mathematica might store a matrix in memory, or why when you evaluate 1/.99999 it returns .00001, but if you add one more 9 to the denominator it returns 1., then Knuth's book is a good one to turn to.

Knuth does not use a high-level language to describe computations--instead he uses a made-up computer called the MIX 1009, which has its own machine language. He came up with 1009 by taking 16 of the machines at the time and taking the average of their numbers (360, 650, 709, 7070, U3, SS80, 1107, 1604, G20, B220, S2000, 920, 601, H800, PDP-4, and II) He also points out that you can derive the same number by taking the name as Roman numerals. If that makes you laugh, you will also find it to be a deeply funny book.


This is definitely not usable as an early intro to CS book, as it's pretty dense. There's a wide variety of introductory material that you can pick from, depending on your interests (what kind of stuff are you interested in doing). But TAOCP is aimed at someone a bit more advanced. Since you have a math background though I think you could give it a shot and see how far you get.


Do you want to learn computer science or programming? The two are only tangentially related.


tAoCP is not just a computer science book, in a sense It is part of the foundation for the field. That said, it is not so much theoretical as it is descriptive. In it [or them] Knuth describes algorithms. and programs and the mathematics of their execution. The sort of code described is for the things people use every day.

It's good reading if a person is fascinated by the subject. Otherwise it will be very very dry. Among the otherwise's, would be someone hoping to pick up a language or someone who wants an introduction to programming. With a math degree, you should not struggle with the math.


These books are good for humbling people who think they know a lot about computer science. They are definitely not good for introducing people to computer science.


Don't use this series as your introduction.

Knuth attempts to build the discipline more or less from the ground up, using a mathematical perspective, and he actually more or less succeeds. The resulting books are awesome as references, but they're incredibly information-dense: not beginner-friendly at all.


If you are coming from mathematics and want to learn programming, you should pick a language first and learn to compile, run, and debug it. Then just about any introductory programming text would serve you fine.

But learning computer science can be much different than learning software engineering. If you want to learn algorithms analysis, I would suggest you read, in order, Sipser and then pick and choose parts of CLR+S. This will give you a good overview of what is important and how proofs of correctness and complexity analysis are done.


Can't speak to this particular book, as I haven't read it, but the best starting point for you depends what you want to learn CS for - do you want to build apps, or do research, or dabble in a bunch of topics just for the sake of learning, or something else entirely? The basics of CS "theory" (ie. Big O notation, searching/sorting algorithms, etc) are useful for any programmer - but beyond that, there are many directions you can take.


What do you want to learn? Programming or CS? CS is more than just programming, and CS theory is more than just Algorithms & Data Structures.

If you want to learn about Algorithms and Data Structures and you have a strong math background, then CLRS is the book to get: http://www.amazon.com/Introduction-Algorithms-Thomas-H-Corme...

An undergraduate CS curriculum will mostly cover the parts I-VI of the book (that's around 768 pages) plus a few chapters from the "Selected Topics Chapter" (we covered Linear Programming and String Matching). Mind you, this book is very theoretical, and all algorithms are given in pseudocode, so if you don't know any programming language, you might have to go with a an algorithms textbook that is more practical. In my DS course we had to implement a Red-Black tree and a binomial heap in Java, and in my Algorithms course we only wrote pseudocode.

Maybe Sedgewick's (Knuth was his PhD advisor!) "Algorithms (4th ed)" will be a better choice for a beginner, as it shows you algorithm implementations in Java: http://www.amazon.com/Algorithms-4th-Edition-Robert-Sedgewic... (If you decide to go this route, you might as well take his two Algorithms courses on Coursera, they will really help).

There are also a bunch of Python-based introductions to computer science which have a broader focus than just teaching specific data structures and algorithms. Some of them emphasize proper program design, debugging and problem solving. I haven't read any of them, so I can't vouch for them, but here are a few of the more popular ones:

* http://www.amazon.com/Introduction-Computation-Programming-U...

This book was written to go along with John's edX course: https://www.edx.org/course/mitx/mitx-6-00-1x-introduction-co...

* http://www.amazon.com/Python-Programming-Introduction-Comput...

Oh and btw, there's also the Theory of Computation, which is a major part of CS theory. Here are a few MOOCs and recommended books on the subject:

MOOCS:

* https://www.coursera.org/course/automata

* https://www.udacity.com/course/cs313

Books:

* http://www.amazon.com/Introduction-Theory-Computation-Michae...

Sipser's book is probably the best introduction to the theory of computation, and I believe its last chapter deals with Complexity theory as well.

* http://www.amazon.com/The-Nature-Computation-Cristopher-Moor...

I loved this book very much. It has a very informal and conversational style (don't let it fool you, the problem sets can be HARD).

* http://www.amazon.com/Computational-Complexity-A-Modern-Appr...

Once you are familiar with some computation models, its time to study computational complexity and this is one of the best books on the subjects. It is used both for graduate and undergraduate courses.


While i'm glad about taocp being more available, my experience with Pearson and their ebook systems (due to their grasp on academia) quickly made me stop considering the purchase.


FWIW, it's cheaper at Google Play: $9.99


Link: https://play.google.com/store/books/details/Donald_E_Knuth_A...

edit: apparently this isn't the correct version, my mistake!


That is not the same book that the publisher lists as being offered in eBook form. I wonder if that is in fact not the same new eBook format that Knuth wrote about having approved?


Headline links to Volume 1, Fascicle 1. You have linked to Volume 4, Fascicle 4. Also, your like doesn't appear to be an eBook.


the description paragraphs wrap mid-word in IE and FF. fascinating.


Their stylesheet https://play.google.com/static/client/css/2587577817-lowlife... has these styles in it:

  .multicol-column {
    -ms-word-break: break-all;
    word-break: break-all;
    word-break: break-word;
  }
Very strange!


Is Google Play in PDF? I think the link from OP offers ebook in PDF, which I can read from iBooks.

Oddly enough, it's not published on iBooks.


This is probably OT, but how much is MIX/MMIX still used in the new books coming out? Volume1 had MIX code for everything, and IIRC by Volume3 it wasn't as pervasive.

Does Volume4 have MMIX code for all algorithms presented?


FYI, this is just a PDF. It's not in ePub or mobi formats.


Is there a sample chapter or section available. I normally like to see how an ebook containing math looks like on the different devices before buying.


See the other comments. If the result pleases Knuth, it probably is good enough for you, too.


Did Knuth read it on a 7-inch screen, or is the font going to be uncomfortably tiny without a lot of zooming and panning?


      For context:
      Knuth created TeX.


http://www-cs-faculty.stanford.edu/~uno/fasc1.ps.gz

That's the postscript version of an unmaintained version. You can probably convert it to pdf and it ought to be similar (sans links, errata fixes and other changes) to the purchasable version with respect to the math layout.


To late to edit, picked up the ebook, compared it to the linked document, pretty much the same if you want to see how the typesetting looks. The ebook version is a pdf of the book with hyperlinks connecting a number of text locations making it easy to go from code to description to whatever else.


who should read those book, i know for sure they are not for the average IT/Programmer guy

who is the right audience, and what would be a prerequisite reading


He starts at the beginning with math and works his way up. Your average IT/programmer guy will probably not have read this book, but it covers all the basics. Think of it as a replacement for a CS degree or at least the lower division courses.


I liked the books as references. I really only worked through most of Volume 1. followed by a detour into Concrete Mathematics. I have made frequent use of Volume 2 and Volume 3 as reference volumes. In college they were invaluable when professors selected some awful textbooks by providing explanations of certain algorithms and concepts and data structures.


I filled out their survey and it only cost me $11.xx.


I can't wait until the rest of the volumes are offered. This particular volume is just a small supplement.


This link is only for a tiny section of "The Art of Computer Programming".


Misleading title. This is only a tiny section of TAOCP.


What I really wanted to share was Knuth's announcement on his own website, which is that (1) this first small chunk of TAOCP is available now in eBook form, and (2) much more of TAOCP will be released in eBook form next year. Linking to Knuth's news.html page seemed wrong, since it's not a static link to this topic, so I linked to the current product offering, and then posted a comment here with more details.

No misleading intended, but I apologize for it coming across that way.


If you are learning to program in Rails, www.hackhands.com will be a great resource. It is a real time expert marketplace where you can instantly connect with an expert (Uber for programmers). If you are a Rails programmer, sign up to become an expert today so you can get paid to help others and build your reputation.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: