There isn't a significant loss in velocity in adapting to use one or the other or even simultaneously (front_end_javascript, BackEndJava, SELECT * FROM blah). The most significant portion of my time is spent thinking/designing/debugging; I save the balls-to-wall frantic keyboard banging for NCIS cameos.
CamelCase vs. underscores: Scientific showdown
21–30 of 60 posts
Re: CamelCase vs. underscores: Scientific showdown
#22I really like underscores for two word variable names. It only becomes a problem when you have variable names which are overly long, and your eyes have to move further. if(Accounts_Orders_Invoices_Table.Order_Invoice_Number == Order_Invoice_Number){ ...} if(AccountsOrdersInvoicesTable.OrderInvoiceNumber == OrderInvoiceNumber){ ... } But I don't really care that much. I'll just do whatever everyone else is doing. At l…
Among the many reasons I prefer Dvorak is that dash/underscore is on the home row.
Re: CamelCase vs. underscores: Scientific showdown
#23Earlier quoted context omitted.
Agreed, although python convention is for underscores also. According to pep8 "Function names should be lowercase, with words separated by underscores as necessary to improve readability. mixedCase is allowed only in contexts where that's already the prevailing style"
PEP8 also says "Class names should normally use the CapWords convention."
Re: CamelCase vs. underscores: Scientific showdown
#24Try choosing independently of (language) convention, habit or type of the identifiers. That's the non-starter for me right there. I use whatever convention makes sense in the context of what I'm doing. Language, library and previous code in an existing project all dictate my choice in this matter.
Re: CamelCase vs. underscores: Scientific showdown
#25Also, the expression "scientific showdown" about studies that rely on psychological self-reporting is a bit of a stretch.
Re: CamelCase vs. underscores: Scientific showdown
#26Re: CamelCase vs. underscores: Scientific showdown
#27As of right now the results are as follows: - CamelCase 52.34% (4,493 votes) - underscores 47.66% (4,092 votes) Which kind of says it all. Use whatever style you want, stop worrying so much about what other people are doing. Variable names a far more important than the formatting you use with them.
Interestingly, the end of article poll has very different results, - CamelCase 43.84% (1,117 votes) - underscores 56.16% (1,431 votes) The beginning poll still is still within half a percent of your numbers as of now. Apparently, people who prefer underscores are more likely to follow through. ;)
Or perhaps they're predisposed to underscore their arguments. :)
Re: CamelCase vs. underscores: Scientific showdown
#28Funnily enough if we want to be semantically correct then CamelCase is wrong and camelCase is right.
Re: CamelCase vs. underscores: Scientific showdown
#29I really like underscores for two word variable names. It only becomes a problem when you have variable names which are overly long, and your eyes have to move further. if(Accounts_Orders_Invoices_Table.Order_Invoice_Number == Order_Invoice_Number){ ...} if(AccountsOrdersInvoicesTable.OrderInvoiceNumber == OrderInvoiceNumber){ ... } But I don't really care that much. I'll just do whatever everyone else is doing. At l…
> At least camcelCase keeps me from reaching for the _ as much... Among the many reasons I prefer Dvorak is that dash/underscore is on the home row.
Re: CamelCase vs. underscores: Scientific showdown
#30That said, I've found that the style isn't nearly as important as consistency. Generally speaking, an inconsistently styled code base is a sign that the developers didn't really care about their work...