this post was submitted on 06 Feb 2024
103 points (94.0% liked)

Programming

18142 readers
433 users here now

Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!

Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.

Hope you enjoy the instance!

Rules

Rules

  • Follow the programming.dev instance rules
  • Keep content related to programming in some way
  • If you're posting long videos try to add in some form of tldr for those who don't want to watch videos

Wormhole

Follow the wormhole through a path of communities [email protected]



founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
[–] hawgietonight 16 points 1 year ago* (last edited 1 year ago) (6 children)

Myth: code can be ugly as long as it works, don't spend company time on making it look good or on minor optimizations.

The truth is that you can tell when effort has been put into a job. Even if it just works, the lack of discipline means that in the end it will be difficult to maintain and probably will fail in unexpected situations.

Every language has its conventions, but if I spot more than a line of separation between blocks of code, that is a common telltale sign of noob. Run from that shit.

[–] [email protected] 9 points 1 year ago (5 children)

Lines of separation are bad? I like adding a few empty lines to denote a different logical section so it's easier for me to read back later :c

[–] hawgietonight 6 points 1 year ago (1 children)

One line is fine if used wisely, everybody does it for readability. The issue is when you need more than one.

[–] [email protected] 2 points 1 year ago

PEP8 is looking at you

load more comments (3 replies)
load more comments (3 replies)