DEV Community

Tim-Ole Sanmann
Tim-Ole Sanmann

Posted on

Bad habits

Hello everyone,

today I was thinking about bad habits while writing code for a project. After a while I realized that my functions are way to long with to much different actions inside. That made me thinking about my schooltime. I remember, when I was at school, there was one thing, beside being lazy, where I earned critic for very often. It was, that I write to long sentences with to much information. My teachers and also my parents told me that pretty often. Even when I left school and applied for my first job as a programmer, my parents and my friends read the application and told me: "Make shorter sentences! You can write everything what you want, but not everything in one sentence."

I realised that there seems to be a connection between writing too long sentences and too long functions. It's the bad habit to try to put all my information into one context which is logical to me. But this is often exhausting for others.

It's interesting to find a connection between behaviors through a habit.
What about you? Do you have any habits in some areas which you can reflect on the way you write code?

Cheers, Tim

Top comments (1)

Collapse
 
gmartigny profile image
Guillaume Martigny

That's an interesting approach. I'm sure most of our personality transpire in our code. Now that I think about it, all the old worn-out debate (OOP vs functional, semi-colon or not, space vs tabs ...) come from different personalities clashing with each other.

I honestly have no idea what trait of my personality reflect on my code. Apart from being lazy I guess. 😉