Book recommendation to learn basics of Comp Sci?
I'm a mid 30s web dev (LAMP stack), self taught, made a decent career from it for the last 10 years but now I'm keen to actually learn programming properly, with the aim to actually learning a 'real' language later.
What's the best books to read to give an introduction to computer science? Assuming zero background, no college/uni education, etc. Sure I don't exactly have zero experience but I'd like to approach it like I did, and learn it all from scratch.
10 comments
[ 3.8 ms ] story [ 25.3 ms ] threadStart with Code by Charles Petzold.
https://www.reddit.com/comments/ch0wt/a_reading_list_for_the...
Definitely take a look at SICP (http://mitpress.mit.edu/sicp/full-text/book/book.html) and the related HTDP (http://www.ccs.neu.edu/home/matthias/HtDP2e/) -- both will require you to get used to Scheme (it's good for you!), but will expose you to the underlying theory of how to compute, which is critical.
Before those two, you could also start with O'Reilly's "Understanding Computation," which is a bit more Ruby-centric than I prefer, but a non-rigorous take on the same subjects. Petzold's "Code" is also a good, non-specialist place to start. (Petzold's "Annotated Turing" is great, but I'd leave it for a while.)
You should read the "Schemer" series (Little, Seasoned, Reasoned) -- again, lots of Scheme, but wonderful if somewhat idiosyncratic reads.
Going back in time, Wirth's "Algorithms + Data Structures = Programs" is a classic in the field, and a pleasure to read.
CLRS' "Intro. to Algorithms" is a foundational text on algorithm analysis and design, though you might also want to try some of the more popular treatments first (O'Reilly has a few good ones). See also Skiena's "Algorithm Design Manual."
The "Dragon Book" (Compilers: Principles, Techniques, and Tools) by Aho, Sethi and Ullman is on every computer scientist's bookshelf for good reason -- it tells you everything you need to know about how the languages you use are built. I also like Holub's "Compiler Design in C," though it's a lot more hands-on.
For understanding OSes, I recommend "The Magic Garden Explained," and Bach's "Design of the UNIX Operating System." Outdated, perhaps, but outstanding in their clarity.
C (yes, you should learn C; like Lisp, it's also good for you even if you only use it rarely): King's "C Programming: A Modern Approach" (though you could start with a popular introduction like O'Reilly's "Head First C"), Plauger's "Standard C Library," Hanson's "C Interfaces and Implementations," and O'Reilly's "Understanding and Using C Pointers," as a start. Van der Linden's "Expert C Programming" is an excellent intermediate text that is also surprisingly readable.
Architecture and design miscellanea: Kernighan's "Practice of Programming," Bentley's "Programming Pearls," McConnell's "Code Complete," and Hunt and Thomas' "Pragmatic Programmer."
I have not yet read, but intend to, Okasaki's "Purely Functional Data Structures."
Make a habit of browsing second-hand bookstores and picking up older computer science books -- they cover by necessity much more foundational issues than most modern books, and do so using simpler architectures and languages. (I have a wonderful text on 68008 programming that has absolutely no practical relevance to the current age, but provides fantastic insights into the nuts and bolts of hardware and OS development.) As a bonus, you'll see how few ideas in computer science are truly new -- as computational bottlenecks shift, theoretical technologies suddenly become practical, or practical ones become outmoded.
You will want Knuth's TAOCP (especially since you mentioned you've had trouble with sorting and searching algorithms), but it's not something to start with. Likewise, Hopcroft and Ullman's "Introduction to Automata Theory, Languages and Computation" is a crucial text, but it's highly abstract (much more so than Knuth, which is a very practical work) and very, very slow going. Pick it up later when you're comfortable with mathematical formalisms.
You'll want to, relatively early on, find a readable introduction to discrete mathematics (the mathematics of "countable" objects, like sets and integers) and some of the more useful optimization techniques like linear programming. I used Grimaldi's "Discrete and Combinatorial Mathematics" to good effect.
Eventually, pick up some good textbooks on programming language design (not parsing and compilation), like Turbak et al's "Design Concepts in Programming Languages" and Finkel's "Advanced Programming Language Design."
Also, a few more sitting on my bookshelf that I also highly recommend -- "Computer Organization and Design," "Operating System Concepts" (the famous "Dinosaur book"), and (if you want to get into the nuts and volts of hardware), Horowitz's "Art of Electronics." Great works.
That should tide you over for the next few years -- but it'll be fun reading. Really!
Do you feel like not studying CS has ever held you back? Whenever I'm struggling to understand something I always wonder if a grasp of basic CS concepts would have helped.
- Played around with making websites from the very early days of the web (gray backgrounds, black text, blue/purple links, <hr>'s everywhere, that kinda thing).. mostly personal projects and small sites for friends/family. Did this for many years, until discovering dynamic content via CGI scripts.
- Got obsessed with CMSes.. Red Dot, PHP-Nuke, rolling my own CGI scripts, DHTML, then PHP etc. Small hobby turned into obsession.
- In the mid/late 90s I started doing freelance websites for local businesses. Family contacts, local shops, etc.
- Mid 2000s quite my retail management career and started a small business with a friend, still just doing websites for local shops, friends of friends.
- Did a few contracts for larger companies (TelCos, local Gov't), fixing up their websites or installing CMSes (WordPress, Drupal, SharePoint).
- One of those Gov't contracts was a 3 mth contract to redesign and rebuild their website from scratch (static HTML site to a large Drupal multi-server deal), they really liked me, hired me full time for more money than I'd ever made in my life, to manage the website and build a decent sized web team, which I've done ever since.
Everything I learned was from books, IRC and Google (.. and before that, AltaVista, Compuserve, etc). I've never done any courses or education past dropping out of high school. I just live, breathe, sweat and crap Web. Subscribe to hundreds of RSS feeds and blogs, have 100-odd books, etc.
I don't think not knowing CS ever held me back, but I definitely hit problems I couldn't solve without that knowledge (Sorting/searching data, the maths side of JS, etc).. I've just been lucky enough to know some really REALLY good programmers to trade help for beer, when it comes to those problems. Those friends have shown me how amazing CS is beyond web stuff, and for a decade now I've been meaning to learn to do "proper" programming and kept putting it off.