DEV Community

Discussion on: Loops are bad, algorithms are good! Aren't they?

Collapse
 
sandordargo profile image
Sandor Dargo

Thanks for your comment, Loik.

You just pointed out that I was inconsistent! It's funny because my only "rule" for the && vs and debate is to follow the conventions of the given codebase.

Though I personally prefer the old way. But it's just personal preference. Good IDEs will warn you on bitwise operators and you can even activate some compiler warning as far as I know.

Sonar, Misra et al. often don't like digraphs/trigraphs and alternative tokens, so whether to use them is also a matter of what rules you try to be compliant with.