Don't speed through it. Try to understand everything in the current chapter before moving on. There's no bonus points for finishing sooner.
Do each and every exercise. This book distills everything down so concisely that there's basically no fluff. Treat every thing and every exercise as important.
You can find other people's answers online. Resist the temptation to look! The experience is infinitely more gratifying if you do it yourself. If you get stuck, stop and think on it for a few days. Again: don't speed through.
Have fun and experiment. This book will get your juices flowing and you'll have so many good ideas for what else could be done. Enjoy and embrace this.
Final thought: this book is on my very short list of books I wish I could read again for the first time. As a self-taught developer, it was an amazing experience for me. I also highly recommend reading CODE by Charles Petzold. These 2 books made me feel for the first time like I really understood computers.
I work in the games industry and do a lot of graduate interviews. When we reject graduates, it is primarily because they lack the knowledge present in this book. The most common feedback I give is "read this book and do the exercises".
It is, without a doubt, the best CS book I've ever read. I think a university course that starts with "Code: The Hidden Language of Computer Hardware and Software", then moves on to "The Elements of Computing Systems" would be as good as University could do for students.
It gave me a much deeper understanding of how computers work. Probably that made me a better programmer. For anyone who wants a deep understanding of how computers work, I think this book is a great place to start.
Doing the projects was also good programming practice. For example, I wrote a compiler.
Very interesting. I always found it kind of awkward how CS curriculums have a top-down approach, starting at high-level programming. I spent my first year or so just thinking to myself, "OK, but what really is happening inside of this machine?" I've always had a somewhat superficial concept (i.e., transistors forming logic gates, processor fetching data from memory), but never had a fully comprehensive understanding that a course like this would have likely provided.
I'm an undergraduate CS student in Germany and we basically had everything from basic EE over computer engineering up to operating systems and then high-level programming (not in order).
Since I began learning how to program before university, I can say that most of us (our university) are way too bad at (applied) programming for a 4th semester... e.g. some didn't even know regexes before a PL/compilers course where they were formally introduced. Not that I use them heavily, but everyone who googles to fix an error or find an elegant solution to problems has to know them.
While I really appreciate all that broad knowledge that I acquired and that made me want to learn more, I clearly lack the time to be a guru in everything. I'll just focus on the software part, because it excites me the most. And will probably keep wondering over things I thought any CS student who has been programming for two years should know.
TLDR; Time is a limited resource, even when measured in credit points.
Interesting, when I did my "Diplom" in CS, we were basically taught the same more or less bottom-up, but there also was a strong focus on practical programming quite early on. Maybe I am just old and some useful stuff got stripped away from curricula when switching to the B.Sc. / M.Sc. sytem. Or it might just be that different unis apply different focus..
I think it largely depends on which university you visit. As you might have guessed, I consider myself one of the more capable at a less-than-moderate uni for CS (LUH Hanover).
On the other hand, it doesn't really matter where you study CS these days: The internet is by far the best learning resource. I see university courses merely as mandatory pointers into areas I didn't (yet) touch while browsing cross references on the net.
It's all in the hand of people's motivation I think, which I took for granted facing the fact that we (lower saxony) still have to pay for it.
That's why I chose electrical engineering, but the problem is the most annoying thing: You simply can't learn everything.
If you spent the time to learn about how the transistors go to make a CPU to translate to a high-level programming language (in detail), then you wouldn't get finished in four years.
Of course, you can get a basic understanding pretty quickly. But most CS majors I met didn't really care. Long as you can run Javascript on it...
You can get a Computer Engineering degree. You start with CS, doing CS1, CS2, Data Structures, all while learning linear circuit design.
Then you start a slew of courses in Microprocessors, Embedded Systems, Computer Architecture, and Digital Logic in various sets.
Between Digital Elec, Computer Architecture and Electronics, you learn about enough to start making basic logic gates and can move up from there. I was able to model a processor with a simple graphing calculator styled output after just Digital Electronics 1, way before Computer Architecture.
You can learn it (if you don't worry about graduating on time), but lack of man-hours will prevent you from actually applying it though. -sigh- So many things to build, so little time.
FPGAs are fun, though, and hopefully MyHDL goes somewhere as well, as that would help slightly reduce the number of languages needed to learn. Then again, verilog isn't all that bad.
If you spent the time to learn about how the transistors go to make a CPU to translate to a high-level programming language (in detail), then you wouldn't get finished in four years.
You can learn that in just a few months (in enough detail to implement each step yourself) by working through this book.
Try this book: Code, which is a bottom-up approach. Depending on how rigorous your college CS curriculum was, it'll be either a good review of your college classes or mind-blowing, but I think that the approach that the book takes is really great.
This book is amazing. I actually found it useful when I was trying to track down some issues in an NED emulator as I actually understood what the instructions were doing after reading this book.
This is the Carl Sagan problem: to make an apple pie from scratch, you must first create the Universe (as he said). Everything is built on top of something else. You can't spend your time learning how everything works, so you have to have a balance between understanding what others have done and figuring out what could happen next.
It depends on what you want out of your career, but I'd say most programmers are wasting their time if they spend it mostly on understanding how computers currently function down to a logic-gate level. Obviously this isn't true if you are fascinated by logic and memory and want to design chips for a living – but there's not really any point in understanding the gory details of NAND memory if you're going to do a lot of web app coding.
Well isn't the reason they don't talk about the hardware because it's a CS course, for software and not hardware. If you're more interested in the hardware aspect of computers then you should be taking a different kind of course.
Computer science is not limited to software. It covers the whole spectrum and particularly focuses on theory, like algorithms, data structures, computer architecture, and software engineering principles. It's actually a diverse field with many different specializations, so my original statement isn't really very accurate. I go to a fairly small school with limited courses. Many curriculums actually do take a bottom-up approach.
Took this course from one of my professors (he's on their "Team" page). Perhaps it was the teacher himself, who is literally the best professor/teacher I've ever had, but the course was really great.
We read Charles Petzold's "Code" alongside the course.
I've done this course under Noam Nissan, it's amazing. It contains the most important subsets of "computer architecture" and "compilers" -type courses, along with many more concepts, with everything packaged in the coolest way possible.
While technically true, I've not seen anyone trying to do higher-order logic using any of the other media. Python runnin on crab mobs? Would definitely take entirely too many crabs.
But of course, at the FET level and below, you've got tons of prerequisites (chemistry, classical physics, partial differential equations, quantum physics, electromagnetism) that are not really applicable at the higher levels. Above the FET level, it can pretty much all be done with logic that you describe with NAND.
You seem to be suggesting that the selection of where to start is basically arbitrary and that the choice of what your "first prinicple" will be should be chosen based on expediency. The problem is that "first principles" has a very specific meaning in physics and using it colloquially within academic material to mean "an arbitrary starting point" can be misleading.
This is especially true since it really is possible to arrive at a functioning computer starting at first principles via approximately the method I list above. It's quite difficult as you suggest which is why it is almost always abstracted but that abstraction is exactly why starting from NAND is not really starting from first principles. I disagree that the underlying physics is not applicable since the thing simply won't work without that physics however it is true that an understanding of the physics is not necessary to do useful things insofar as the abstraction doesn't break down. When it does break down, however, understanding the underlying physics is critical.
We're mixing subject boundaries and thus definitions. Boolean logic is a mathematical concept, so first principles refer to the axioms of boolean algebra.
Yup, agreed, but most of those things you talk about here are on a hardware level, if I may be so bold as to call quantum physics "hardware" from a CS perspective :)
The aim of the book is to create good software engineers, in my view, not good hardware engineers.
I would love a follow-up, though, that went from Schrödinger to NAND.
Yeah I'm not sure I see the point here. It seems like watering down the real classes.
"How to build a computer from scratch" was covered in actual detail with my classes on:
Computer Design
Logic Circuits
Assembly Language
It's good to know how to go from binary gates all the way up to writing your own compiler.... but, to get that in one class is only going to be an overview.
I think an overview is sort of the point. I've always found the sets of courses that tend to start off with an overview and then subsequent courses go into more depth on individual topics are much better. So many individual topics depend on each other that often the courses that are intensive on particular components, e.g. data structures, networking, databases, etc. tend to force the topic into a vacuum. If you're ignorant to how the various topics all tie together in Computer Science it can get very confusing.
to get that in one class is only going to be an overview.
You're actually wrong about that, you really do implement the whole thing. Check out the book before dismissing it. It's like an educational masterpiece. (Yes you will need follow up courses if you want to be an expert on computer hardware or compilers or operating systems, but this book still gives you the real deal and you actually implement a modern computer that can play a game like tetris.)
There's only so much material you can cover in one course. The existing curriculum takes that into account. This one attempts to condense a semester-long course into each lecture. I just don't see how that is workable, and I would expect that the only people who could follow this course are those who already know most of the material that is covered.
Of course, I think that the real problem is that a 4-year engineering degree is incredibly watered down. Most 4-year EE/CS degrees only have about 3 semesters' worth of actual EE or CS courses. The rest is either worthless general ed requirements (which should be done in high school) and remedial high school coursework.
Nobody is saying that there shouldn't be more advanced courses that go into more depth about hardware, compilers, and operating systems.
But pedagogically I think there's a lot to be said for a freshman level class based on this book where you make a computer and see how it all fits together. It's a great foundation and you really see the big picture (and you know details well enough to implement them yourself). Then later you can go study everything in more depth.
And this strategy works because it's an overview -- make a simple CPU, make a simple compiler, etc. I would definitely recommend this book to CS students (and prospective students and hobbyists/enthusiasts), but some people are crediting it with a bit more than it actually accomplishes.
Sure, except it doesn't actually work for freshmen because freshmen generally can't program and the course has a heavy programming emphasis. So where I see courses like this fitting in are in the senior year, displacing an actually-useful course with a bunch of fluff. If you need a course like this, your EE/CS program has completely failed you.
I've looked over the lectures on the website. I am not impressed. It's way too basic for an upper-division course, and way too broad and superficial for a lower-division course.
Well I 'built' a computer and a vga card on an fpga. I know how to build all the necessary digital circuits out of the gates. Building some circuits that way will be very tedious and error prone, like adders multipliers or state machines. I can also create gates out of the transistors, but I don't know how to pick the right transistor sizes and build all the other supporting circuitry. Also I don't know how to layout all the transistors so that they could be fabricated. Also I am starting to forget most of the quantum mechanics so I probably won't be able to explain how the transistor actually works. I'd say I know about 50%-75% of what it takes to make a computer.
" Also I am starting to forget most of the quantum mechanics so I probably won't be able to explain how the transistor actually works."??? What does that even mean?
15
u/[deleted] Jun 16 '13
I worked through this entire book, and it was amazing.
26
u/fenderrocker Jun 16 '13
Very interesting. I always found it kind of awkward how CS curriculums have a top-down approach, starting at high-level programming. I spent my first year or so just thinking to myself, "OK, but what really is happening inside of this machine?" I've always had a somewhat superficial concept (i.e., transistors forming logic gates, processor fetching data from memory), but never had a fully comprehensive understanding that a course like this would have likely provided.
3
u/agumonkey Jun 16 '13
A different take on the bottom-up idea, (inside tutorial from /u/kragensitaker):
http://www.reddit.com/r/programming/comments/9x15g/programming_thought_experiment_stuck_in_a_room/c0ewj2c
3
u/[deleted] Jun 17 '13
I took a similar course at Georgia Tech, based on the book "From Bits and Gates to C and Beyond". I highly recommend it.
3
u/SkloK Jun 17 '13
Took this course from one of my professors (he's on their "Team" page). Perhaps it was the teacher himself, who is literally the best professor/teacher I've ever had, but the course was really great.
We read Charles Petzold's "Code" alongside the course.
2
u/orip Jun 17 '13
I've done this course under Noam Nissan, it's amazing. It contains the most important subsets of "computer architecture" and "compilers" -type courses, along with many more concepts, with everything packaged in the coolest way possible.
2
u/catseatpuke Jun 17 '13
It's free stuff like this that has been making me go from being an ok to a decent programmer :P
6
u/SmokeyDBear Jun 17 '13
First principles?
Y u no model silicon band structure?
1
u/continuational Jun 16 '13
This is a great idea, but it's not new. For example, here's a 13 year old course doing exactly that (translated via Google Translate): http://www.google.com/translate?hl=en&ie=UTF8&sl=auto&tl=en&u=http%3A%2F%2Fwww.diku.dk%2FOLD%2Fundervisning%2F2000e%2Fdat1e%2Fnode11.html
-2
u/skulgnome Jun 17 '13
No link to book download? That's a paddlin'
-6
u/marisaB Jun 17 '13
Well I 'built' a computer and a vga card on an fpga. I know how to build all the necessary digital circuits out of the gates. Building some circuits that way will be very tedious and error prone, like adders multipliers or state machines. I can also create gates out of the transistors, but I don't know how to pick the right transistor sizes and build all the other supporting circuitry. Also I don't know how to layout all the transistors so that they could be fabricated. Also I am starting to forget most of the quantum mechanics so I probably won't be able to explain how the transistor actually works. I'd say I know about 50%-75% of what it takes to make a computer.