Style
Although it doesn't matter which style you adopt, it is important to adopt a consistent coding style. A consistent style makes it easier to guess what you meant by a particular part of the code, and you avoid having to look up whether or not you spelled the function with an initial cap the last time you invoked it.
The following guidelines are arbitrary; they are based on the guidelines used in projects I've worked on in the past, and they've worked well. You can just as easily make up your own, but these will get you started.
As Emerson said, “Foolish consistency is the hobgoblin of small minds,” but having some consistency in your code is a good thing. Make up your own, but then treat it as if it were dispensed by the programming gods. ...
Get Sams Teach Yourself C++ in 24 Hours, Third Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.