What is the best way to use whitespace while programming? [closed]
I'm fairly new to programming and from learning I have seen different ways of formatting code, comments, etc; and have been recommended on different techniques. I mostly program in C#, C++, and Java so I want to know what is the the best way to layout code so that if other people where to go through it, they would be impressed by how simple and easy to understand it is. The best rule to follow is: (and probably the only rule everyone will agree on) Be consistent! Pick one style and stick with it. Always put your braces in the same place. Use similar naming conventions. Don't mix tabs and