
-----------------------------------
wtd
Mon Nov 10, 2008 10:33 pm

How to write good C++ code
-----------------------------------
We seem to have a lot of interest in C++.  Here're a few tips on writing code that doesn't suck.

Formatting

Indentation

Use indentation, and use it consistently.

Bad:

void foo()
{
for (int bar = 0; bar < 10; bar++)
{
    cout 