4 ms·
> “Functions should do something, not maybe do something…” But it did do something, it checked if the user logged was logged in first.
by skerit 3y ago
> “Functions should do something, not maybe do something…”
But it did do something, it checked if the user logged was logged in first.
- augustk 3y agoWirth entered the chat: Procedures should do something. Functions should return something. https://en.wikipedia.org/wiki/Command%E2%80%93query_separation https://en.wikipedia.org/wiki/Command%E2%80%93query_separati... By the way, I have never understood the practice of using a verb in the name of a (pure) function; naming the function after its result using a noun or adjective phrase makes much more sense.