Hacker Newsnew | past | comments | ask | show | jobs | submit | jgstyle's commentslogin

> There’s nothing wrong with writing reusable functions, and most well-written functions will be reusable without adding any needless complexity. However, too often I’ve seen developers over-generalize a problem to the detriment of readability.

I think one of the main points why a lot of developers tend to over-generalize is because they are not specific enough with the name of the function they are trying to write. Although it looks dull, I find the best workflow is giving functions (or methods) very specific names.

I think there are two major advantages as to why you should do it: - the problem mentioned in the text of over-generalising is minimised since you are forced to think about what exactly that method should do when creating it, not while writing it. - other people using your code will (to a certain degree) instantly know, what the function method is doing without having to look at the code



Thats actually sort of a cool idea


The design reminded me very much of Craft, which im using currently → What are the advantages of using a card base note system over a regular "file"based one? Obviously, I can see the "visual" difference, but in terms of actual usage, where's the difference?


Not to forget the big cookie banner


Indeed, how could I forget. "We care about your privacy".


I use the app "Things 3" and set deadlines, works pretty Goode... only downside: Its only available in the Apple ecosystem and its not free.

Btw.: its also my preferred Task manager


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: