HN Books @HNBooksMonth

The best books of Hacker News.

Hacker News Comments on
Algorithm Design

Jon Kleinberg, Éva Tardos · 13 HN comments
HN Books has aggregated all Hacker News stories and comments that mention "Algorithm Design" by Jon Kleinberg, Éva Tardos.
View on Amazon [↗]
HN Books may receive an affiliate commission when you make purchases on sites after clicking through links on this page.
Amazon Summary
Algorithm Design introduces algorithms by looking at the real-world problems that motivate them. The book teaches a range of design and analysis techniques for problems that arise in computing applications. The text encourages an understanding of the algorithm design process and an appreciation of the role of algorithms in the broader field of computer science.
HN Books Rankings

Hacker News Stories and Comments

All the comments and stories posted to Hacker News that reference this book.
For the general case, the CLRS book is recommended, but I personally found Algorithm Design by Jon Kleinberg and Eva Tardos to be the best introduction in undergrad: https://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/032...
dmlittle
Despite its name CLRS goes WAY beyond an introduction
The good thing about Algorithm Design & Analysis as a topic is that there is no lack of great resources to learn from! And even better, a large portion of them are freely available online (in forms of lecture notes, or entire books, video lectures, programming challenges with online judging, etc).

In addition to what others have mentioned, here are some example resources you might prefer for a beginner-intermediate level intro:

1. (free online) Algorithms by Dasgupta, Papadimitriou, and Vazirani http://algorithmics.lsi.upc.edu/docs/Dasgupta-Papadimitriou-...

2. (free online) Algorithms by Jeff Erickson https://jeffe.cs.illinois.edu/teaching/algorithms/

3. Algorithm design by Kleinberg & Tardos https://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/032...

4. Another one specifically for more applied view (esp., how they are used in programming contests such as ICPC) is Skiena & Revilla's "Programming Challenges" book (https://www.amazon.com/Programming-Challenges-Contest-Traini...). Note that this is different than Skiena's other popular book (Algorithm Design manual) which is also pretty good and has a "war story" based perspective to design of algorithms.

5. There are also several resources where lecture notes from university Algorithm & DS courses are very useful. Here is an example from my previous Professor, David Kempe: http://david-kempe.com/teaching/DataStructures.pdf

6. Several programming competition specific tutorials can be found on Topcoder: https://www.topcoder.com/thrive/tracks?track=Competitive%20P... (individual SRM archives are also good place to try problems first hand and then learn from other's approach). In general, if you search for ACM-ICPC resources, you will find a lot more targeted information/problems which will apply not only for leetcode, but also for detailed understanding of the theory too.

I studied this topic mainly from Algorithms text by Kleinberg/Tardos[1]. Like everything else, if you interested in proving problems NPC, read few examples from book and practice some on your own. Proving problems NPC of some common problems isn't very hard once you get hang of it.

http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...

Both solid choices. Having used CLRS (the Intro the Algorithms book), I would say it's a fantastic reference, but I found some of the presentation rather terse. It is nothing that a motivated reader can't power through, but some people have also suggested Kleinberg and Tardos's algorithms book for better pedagogical development http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...
What's wrong with less cryptic books like these?

http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...

http://www.amazon.com/Introduction-Algorithms-Third-Thomas-C...

xtacy
Depth.

I have read CLRS (the second book in your list); it's really great as an introductory text as it spans a lot of areas. For example, sorting/searching is a chapter in CLRS, while it's a volume in itself in TAOCP (The Art Of Computer Programming). Also, CLRS is written in the style of a textbook, rather than a reference and a newbie would find it easier to follow. And, TAOCP is more of an in-depth reference to practically everything that has been researched in that field so far.

amichail
How many people need this level of depth?
tomjen3
A lot more than you would think - there are plenty of programmers out there that can't tell you the tradeoffs between the different approaches, and they can get away with it, because it appears to work (see thread synchronization, cross-site scripting, data-base injection, null pointers, pointer overflow, etc, etc) until somebody demonstrates that it doesn't.
glhaynes
thread synchronization, cross-site scripting, data-base injection, null pointers, pointer overflow

Does TAOCP cover any of those?

None
None
tomjen3
I would expect it to have plenty of algorithms to implement mutexes with, as well as parallel sort algorithms.

There are also going to be a lot of pointer based tricks that you don't get unless you really understand pointers.

None
None
Jan 25, 2010 · randliu on Algorithms course material
I'd suggest Algorithm Design by Kleinberg and Tardos: http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321... , it's more readable than either CLRS or Dasgupta/Papadimitriou/Vazirani.
Ah, apologies:

  Algorithm Design
  by Jon Kleinberg & Éva Tardos
  ISBN: 978-0-321-29535-8
Or an Amazon link: http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...
If you are really interested in the math involved you can look at any algorithms book. I used this one in my undergrad: http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...

Its a good introduction, but it will require you to be decent at math and know how to do proofs.

On the other hand, if you are interested in how programs can express things, then maybe you want to learn about some CS theory. Specifically, some lambda calculus would be good to learn, but I don't have any good suggestions.

Note: All of these will be easier to read if you are pretty good at programming, so I'd say follow at least the first piece of advise above.

May 15, 2009 · pz on Ask HN: After SICP, what next?
I recommend the Kleinberg/Tardos textbook: http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...

It is a really enjoyable read and has a nice narrative that I think other algorithm books are lacking. CLR, for instance, just reads like a handbook to me. The goal Kleinberg/Tardos book, OTOH, is to teach you how to design and analyze algorithms. They will actually follow false starts on certain problems and uncover where they break.

Kleinberg is the rebel king!

I dunno about this. Of the books under "books most programmers have actually read," the only one I've read is the C programming language (K&R). But I think I'm probably more likely to read the GoF design patterns book or the rest of my college algorithms book ( http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321... ) than Programming Pearls or Effective Java.
Good introductory text: Cormen/Leiserson/Rivest/Stein: Introduction to Algorithms (2nd edition)

http://www.amazon.com/Introduction-Algorithms-Thomas-H-Corme...

Good advanced text: Jon Kleinberg/Eva Tardos: Algorithm Design

http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...

For routine programming, the GoF Design Patterns book will be more helpful to you than algorithms books.

But if you really want to learn more about algorithms, check out this book:

http://www.amazon.com/Algorithm-Design-Jon-Kleinberg/dp/0321...

As for programming languages, the java + eclipse combination is excellent.

jsjenkins168
The GoF book is great as a design patterns reference (despite its age), but I would personally recommend Design Patterns Explained by Shalloway and Trott if you are new to the concepts.. Its much better at teaching you the thought process of why and when and when not to use design patterns, which is probably more important than the design patterns themselves.
amichail
Also, check out this refactoring book:

http://www.amazon.com/Refactoring-Improving-Design-Existing-...

juwo
thanks. I notice though it may be a bit dated - 1999.
HN Books is an independent project and is not operated by Y Combinator or Amazon.com.
~ yaj@
;laksdfhjdhksalkfj more things
yahnd.com ~ Privacy Policy ~
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.