views:

157

answers:

4

I once started C++ about 3 years ago, and my skill literally frozen up at that point, because I can't find a good practical reading sources that can fill the gap between beginner and expert. I tried to read and understand other expert's open sources code but most of their implements are just too confusing, and most of the time requires a deep understanding of what you're trying to do and what's running behind the scene. I am searching for one but most of what I have found are the ones that teach you about assembly syntax. I know that assembly language give good insight into the computer system, but what I want is a book that give you insight into how to practically use the knowledge of computer architecture on high level language like C++. In other word, a book that not only teaches about the architecture but also teaches about practical uses of computer architecture.

Another kind book that I would want to have my hand on is a book that show how programmer construct a large project/software from ground up. I have always wonder how they build a source code with around hundreds or even thousands of header/source files. Where did they, the programmers, start? I mean creating these hundreds of sources files that are linked together (through import). If I am going to do such one, where should I start? I really want a book that gives insight into these knowledges and probably better WITH practical examples.

A: 

If you're interested in going into details on Computer Architecture then I'd recommend Tanenbaum which has a wide range of books dedicated to this ( http://www.google.com/search?tbs=bks:1&tbo=p&q=+inauthor:%22Andrew+S.+Tanenbaum%22 ).

For C++ a complex beginner to upper-intermediate (not really expert) Deitel & Deitel wrote a good one with lots of examples: C++: How to program http://books.google.com/books?id=hwpqHb5NBSoC

As for building software projects, try Ian Sommerville's Software Engineering, but don't expect to answer your question regarding how the software product has its libraries organised in a couple of pages.

They're thick books, but once you read through them, programming/computer architecture/computer science would look a lot more interesting.

bsuv
IMO, Andrew S, Tanenbaum is, kinda cool book. But I know a lot others for whom it's the exact opposite... :)
liaK
I have Tannenbaum's Computer Networks book (I believe it's the same person.) Good stuff, but not for the faint-hearted.It's also a good 15 years out of date now :)
Ragster
@Ragster are there any better all-around university texts on networking in your opinion?
Victor Sorokin
@Victor - not that know of. Tannenbaum covers the principles (which haven't changed) in some depth, and all the underlying theory is still valid. However it doesn't cover the newer technologies, such as the local wireless spread-spectrum stuff. And the examples are now quite dated. I should see if there are revised editions.
Ragster
A: 

I remember seeing an image online that expressed skill in software development as the ratio complexity of the problem divided by complexity of the solution.

So to increase skill you can either tackle larger problems, or try and come up with smaller, simpler solutions.

Trying to learn by looking at mature complete solutions that have grown over time may help when you are trying to solve a specific problem, but may lead to the symptom of copy-pasting large chunks of complexity to solve problems that don't require it.

I suggest trying to tackle a really simple problem, and solving it the simplest way. Then take on the role of the user and try and add features, once again, the simplest way possible (provided that it is testable, maintainable and understandable). It is also good if it obeys standards design guidelines like the SOLID principles.

If you get stuck on a particular task, as for help.

It sounds like you are interested in software design. Some of the books by Bertrand Meyer and Robert Martin approach this. The Domain Driven Design community looks into the topic fairly deeply and have some excellent ideas in the area of the structure of software and systems both at the design and architecture levels.

Perhaps Design Patterns could be what you are after. The GoF book is the classic Design Patterns book, and is relevant for C++ programmers, but there are other books that are maybe more relevant for learners and more modern languages.

But watch out, a classic anti-pattern that beginners make is to over-apply the patterns for example using a factory where a simple constructor call is sufficient.

Far better than any book is to start a simple program, ideally make it open source and try and get a handful of users, and then slowly add features as simply as possible. But do look around and see how others have solved similar problems first.

Avoiding complexity is half the battle.

I would suggest therefore the following:

Pablo's SOLID E-Book

Design Patterns

Clean Code

DDD Quickly E-Book

Kurt
Keep it simple, that's what I always think. However, I once saw in others' work, they have some kind of namespace encapsulation such as namespace sth1 {namespace sth2 {class class1{.....};}}in its header file, and then a same repetitionnamespace sth1 {namespace sth2 {class1::classfunction() {...}//definition of other functions.....}}in its .cpp file. The question is, why namespaces? Why not just declare a class then leave it like that, why should it be encap into namespace?Another question is, why does 2nd header uses same namespace (sth1 sth2) with 1st one, does this work?
+2  A: 

I'm unsure how to parse your first question. You seem to be talking about computer architecture in the sense of processors and possibly operating systems (rather than software architecture in terms of patterns and qualities). If you want to really understand low level architecture, you'll have to jump into direct assembly programming (and possibly driver development in one or more operating systems). Don't look for generic literature, but focus on understanding Windows or Linux (or your poison of choice!): @bsuv's suggestion of Tannenbaum could be of interest. I'm not sure it's something I personally would look into: there are opportunities in that direction, but in most scenarios, you'll be a much more attractive developer if you understand more about design and software architecture. Look at @Kurt's recommendations instead. I might add e.g. Larman's Applying UML and Patterns which considers not just the design aspects, but also the realities of people having requirements, working in projects with multiple deliveries. It's my favourite one-stop shop for improving your development maturity, and works as introductions to a lot of @Kurt's books.

The best book I've read so far on building large systems with C++ is Large Scale C++ Software Design. It really helped me beat a 500+kSLOC C++ system into shape. Unfortunately, it's pretty dated when it comes to modern C++. It's excellent on how to manage dependencies, but it does not really discuss e.g. templates or address the vast improvements in compilers and linkers since it was written.

Pontus Gagge
+1  A: 

Depends on exactly what scale you're looking for.

It is difficult, because the gap between beginner and expert is a large one (and many people have gaps, at least in some areas - e.g. I know core C++ reasonably, but my STL is not good.)

If you know the basic syntax of C++ and want to know how to apply C++ well, I would suggest Scott Meyer's 'Effective C++' and 'More Effective C++' - they are specifically written to take someone who knows C++ in a basic sense, and give them tools in the language. They're not introductions to the language though.

At the other end of the scale, we have large software architectures. This is somewhere where experience really is the key, and working on large-scale projects is the only real way to get it, I think. That said, you can help get an overview of the sort of architectures that work by reading something like 'Architecting Applications for the Enterprise' (Esposito and Saltarello) - which discusses design tools like UML, and then the large scale structures that have been found to work.

In theory, writing in a mid-high level language, the underlying machine architecture shouldn't matter. In practice, knowing more about the hardware never hurts, and is frequently useful, especially when something nasty comes up in debugging. But for that you'd need to be specific about which hardware you're building on.

The more experience you can get, the better. There's only so much you can learn from books (as much as I love reading them, they have limited value if you never learn to apply the contents.)

Ragster
@Ragster Yeah, so I really want a book that have practical examples (as I request), because I feel that without practice, computer programmer won't go anywhere far.
Practical examples take up a lot of space in a book, mostly with work-horse code that isn't the main thrust of the book's intent. So they tend not to do that. I suspect what would be most useful to you would be to read the books on the principles, then actually write the applications. This takes time, but that time investment is the only way to gain experience. You can't get that from reading. Even if you follow examples in a book, you'll never get real practice without doing it (and failing, and correcting it) yourself. The books help, but they can't do it for you.
Ragster