Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

How to write good C++ code

154 views
Skip to first unread message

Andrea Mondelli

unread,
May 21, 2013, 8:39:27 AM5/21/13
to
I'm looking for a book that teaches how to write GOOD code.
Any suggestions?

A.

Victor Bazarov

unread,
May 21, 2013, 8:52:30 AM5/21/13
to
On 5/21/2013 8:39 AM, Andrea Mondelli wrote:
> I'm looking for a book that teaches how to write GOOD code.
> Any suggestions?

Take a look at www.accu.org, the book review section. Any "recommended"
or "highly recommended" C++ books are worth looking at. I personally
don't know of any specific books that "teach how to write good code", so
my approach has always been to try my best and have it reviewed by peers
and tried by heavy use.

Happy coding!

V
--
I do not respond to top-posted replies, please don't ask
Message has been deleted

Victor Bazarov

unread,
May 21, 2013, 9:59:13 AM5/21/13
to
On 5/21/2013 9:40 AM, Stefan Ram wrote:
> Andrea Mondelli <mond...@gmail.com> writes:
>> I'm looking for a book that teaches how to write GOOD code.
>
> You can read (in this order and doing the exercise):
> Programming -- Principles and Practice Using C++ (only if
> you have not programmed before) or Accelerated C++ (if you
> have programmed before), The C++ Programming Language,
> Effective C++, Exceptional C++ (Parts 1 and 2), and Modern
> C++ programming.

The last title should probably be "Modern C++ Design".

Balog Pal

unread,
May 21, 2013, 2:44:26 PM5/21/13
to
On 5/21/2013 2:39 PM, Andrea Mondelli wrote:
> I'm looking for a book that teaches how to write GOOD code.
> Any suggestions?

I suggest to obtain a mentor, one who can actually write good C++ or
whatever code, then he will set you on books and review your progress.

We have many books that help those who already can write at some level
good code to be better and more consistent. But the first milestone is
way more tricky, and I doubt books can realistically cover it.

Puppet_Sock

unread,
May 23, 2013, 10:04:43 AM5/23/13
to
On May 21, 8:39 am, Andrea Mondelli <monde...@gmail.com> wrote:
> I'm looking for a book that teaches how to write GOOD code.
> Any suggestions?

In the category of "transferable skills" I would suggest
_Code Complete_ by Steve McConnell. Many good suggestions
that are less specific to a particular coding language.
These will mostly be useful in C++ or any coding language.
Socks

Anand Hariharan

unread,
May 23, 2013, 11:10:30 AM5/23/13
to
Couple of suggestions:

1. Sutter and Alexandrescu, C++ Coding standards
2. Dewhurst, C++ Gotchas
0 new messages