this post was submitted on 12 May 2024
227 points (98.7% liked)

Asklemmy

43866 readers
1832 users here now

A loosely moderated place to ask open-ended questions

Search asklemmy ๐Ÿ”

If your post meets the following criteria, it's welcome here!

  1. Open-ended question
  2. Not offensive: at this point, we do not have the bandwidth to moderate overtly political discussions. Assume best intent and be excellent to each other.
  3. Not regarding using or support for Lemmy: context, see the list of support communities and tools for finding communities below
  4. Not ad nauseam inducing: please make sure it is a question that would be new to most members
  5. An actual topic of discussion

Looking for support?

Looking for a community?

~Icon~ ~by~ ~@Double_[email protected]~

founded 5 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[โ€“] [email protected] 2 points 6 months ago (1 children)

Genuinely curious - what do we know makes code very bad?

[โ€“] xJREB 3 points 6 months ago

A few bad things in code for which we have fairly consistent evidence:

  • high nesting depth
  • meaningless or single-letter variable names
  • lots of code duplication
  • very inconsistent formatting
  • very complicated Boolean conditions with AND and OR
  • functions with a lot of parameters