Become a fan of Slashdot on Facebook

 



Forgot your password?
typodupeerror
×

Comment Re:Learn C and Python (Score 2, Insightful) 997

... and those extra semi-colons "just in case" are also ugly.

En garde!

To me, omitting syntax that isn't strictly necessary is a form of premature optimization. It takes more work to determine whether a statement needs to be terminated with a semi-colon than it does to subconsciously terminate _every_ statement; it takes more work to translate between the block and inline form of an if-statement as code evolves; it takes more work to rearrange case statements if some include an implied break.

I used to strive for "compactness" in my code. When I realized how much keeping track of all my own formatting rules and exceptions was costing me brain cycles (plus the aforementioned issues), I switched to striving for consistency.

Slashdot Top Deals

THEGODDESSOFTHENETHASTWISTINGFINGERSANDHERVOICEISLIKEAJAVELININTHENIGHTDUDE

Working...