Comment on I wish

<- View Parent
BeigeAgenda@lemmy.ca ⁨1⁩ ⁨year⁩ ago

No its not the wrong solution! Premature optimization is a waste of time.

Using if or case is not a solution because it is way too verbose and very easy to introduce an error.

Modulo is a solution, and using bit-wise and is another faster solution.

source
Sort:hotnewtop