Check if a number is even or odd in python
Check if a number is even or odd
This program takes a number (num) and checks if it is even or odd using the modulo operator (%). If the remainder of num divided by 2 is 0, then it is even. Otherwise, it is odd.
Comments
Post a Comment