Sunday, September 20, 2009

Curly Braces

You know what is one thing I hate? When people put curly braces on the same line as the function declaration. Look at the following example in C:
int fact(int a){

blah blah blah

}
That is dumb! It should be like this:
int fact(int a)
{

blah blah blah

}
It makes it a hell of a lot easier to read it than the first way. For some reason CS majors tend to me more guilty of this than other majors. You shouldn't do this. I look at the code and I hate it when someone does this.

0 comments: