You are not logged in. Your edit will be placed in a queue until it is peer reviewed.
We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.
- 6This is bad. Even beginner level textbooks don't do this atrocity. "Code is read 10 times more than it's written"... all the more reason not to waste the reader's time with this code cruft.Thomas Eding– Thomas Eding2012-04-04 20:20:24 +00:00Commented Apr 4, 2012 at 20:20
- @trinithis What if you have 20-case switch statement? Sometimes you need to support 20 different options, and it's better to have them gathered in one place than "refactored" into some multi-level decision-making scheme.quant_dev– quant_dev2012-04-05 10:07:59 +00:00Commented Apr 5, 2012 at 10:07
- i believe this is a practice by coders who underestimate peers :) that others are not smarter enough to read the code unless. gnerally i am against this practice, but okay if someone does it coz there is a jungle of }s that makes it hardly readable. i dont do that anyways!WinW– WinW2012-04-05 11:15:27 +00:00Commented Apr 5, 2012 at 11:15
- 1@trinithis It's not about whether it's bad or not, it's about effective ways to help people get better so they grow through it. Being effective > being right. It's also a perfectly sensible thing to do if, say, you're refactoring legacy code that's even more of a mess. Sometimes bad things can make better interim steps and lead to something even better than that.Lunivore– Lunivore2012-04-05 11:35:56 +00:00Commented Apr 5, 2012 at 11:35
- 1@trinithis Sorry, I can't work out what you mean when it's all on one line like that. I think I mentioned that there are also other ways of refactoring code that devs doing this could learn.Lunivore– Lunivore2012-04-05 17:34:53 +00:00Commented Apr 5, 2012 at 17:34
| Show 1 more comment
How to Edit
- Correct minor typos or mistakes
- Clarify meaning without changing it
- Add related resources or links
- Always respect the author’s intent
- Don’t use edits to reply to the author
How to Format
- create code fences with backticks ` or tildes ~ ```
like so
``` - add language identifier to highlight code ```python
def function(foo):
print(foo)
``` - put returns between paragraphs
- for linebreak add 2 spaces at end
- _italic_ or **bold**
- indent code by 4 spaces
- backtick escapes
`like _so_` - quote by placing > at start of line
- to make links (use https whenever possible) <https://example.com>[example](https://example.com)<a href="https://example.com">example</a>
How to Tag
A tag is a keyword or label that categorizes your question with other, similar questions. Choose one or more (up to 5) tags that will help answerers to find and interpret your question.
- complete the sentence: my question is about...
- use tags that describe things or concepts that are essential, not incidental to your question
- favor using existing popular tags
- read the descriptions that appear below the tag
If your question is primarily about a topic for which you can't find a tag:
- combine multiple words into single-words with hyphens (e.g. design-patterns), up to a maximum of 35 characters
- creating new tags is a privilege; if you can't yet create a tag you need, then post this question without it, then ask the community to create it for you