brianmanahan
Lifer
- Sep 2, 2006
- 24,637
- 6,016
- 136
comments simply aren't necessary if you have code written that way.
do not use underscores in variable names ... that is bad code!
(semi serious about this too, i can't stand it - camel case ftw!)
i am a java programmer, but i honestly find underscores to be more readable
i dont do it in production code, but use it in test case method names
what is more understandable?
1. public void calculatePremiumReturnsCorrectFactorCoefficients()
2. public void calculatePremium_returns_correct_factor_coefficients()
i vote for #2
Which version are you using? I'm using 2013 Express. If I type this:
and hit enter, it automatically turns into this:Code:if (condition) {
All of the settings are on default.Code:if (condition) {
i am a java programmer, but i honestly find underscores to be more readable
i dont do it in production code, but use it in test case method names
what is more understandable?
1. public void calculatePremiumReturnsCorrectFactorCoefficients()
2. public void calculatePremium_returns_correct_factor_coefficients()
i vote for #2
#1 is easier on the eyes for sure, also easier to type.
code is like jokes
if you have to explain it, it's bad
Hello,
I'm new to computers, and at this point my metric for what constitutes good programming is functionality. That is, if a piece of code simply does what it's supposed to, in my eyes it's good.
However, I'm aware enough to understand that even though code may be functional, it may still be poorly constructed.
So, experienced programmers, how do you know when looking at source code whether or not the writer knew what he was doing?
What are the hallmarks of good programming? What are the hallmarks of bad programming?
Can you recommend certain coding styles to emulate? Can you admonish me from emulating others?
Thanks.
i am a java programmer, but i honestly find underscores to be more readable
i dont do it in production code, but use it in test case method names
what is more understandable?
1. public void calculatePremiumReturnsCorrectFactorCoefficients()
2. public void calculatePremium_returns_correct_factor_coefficients()
i vote for #2
I am going to print this out and put it up at work. LOL!code is like jokes
if you have to explain it, it's bad
I am going to print this out and put it up at work. LOL!
There are contexts in which all-caps is not only unobjectionable, but increases comprehension. Specifically, case-insensitive languages like SQL. The reason that the upper-case convention was adopted for SQL keywords early on is simply that when the language is not case-sensitive you end up with everyone using their own personal approach, i.e. select, Select, and SELECT.
I did not claim this. Though I find all uppercase no harder to read 95-99% of the time.I'm not sure how anyone can defend Ken's claims that all uppercase is always easier to read
I can agree with this. Especially when the convention is to not use all caps.There *is* something wrong in using all caps when not convention
Which version are you using? I'm using 2013 Express. If I type this:
and hit enter, it automatically turns into this:Code:if (condition) {
All of the settings are on default.Code:if (condition) {
