You could also use bitwise operators. I don’t fully understand them myself but they are extremely powerful and efficient operators! Here’s a quick way to find if a number is odd or even:
Even is true; odd is false.
You could also use bitwise operators. I don’t fully understand them myself but they are extremely powerful and efficient operators! Here’s a quick way to find if a number is odd or even:
Even is true; odd is false.