Contents
In this example, we will demonstrate how the functions work. EVEN (EVEN) and ODD (ODD) in Excel. You will also learn how to determine if a number is even or odd.
CHOTN
- Round a positive number to the nearest even integer.
=EVEN(A1)
=ЧЁТН(A1)
- Round a negative number to the nearest even integer using the same formula.
WHY
- Round a positive number to the nearest odd integer.
=ODD(A1)
=НЕЧЁТ(A1)
- Round a negative number to the nearest odd integer using the same formula.
Even or odd?
One way to determine if a number is even or odd is to use the function MODE (REMAIN). Function MODE (MOD) returns the remainder of a division.
- Even integers divided by 2 always leave a remainder of 0. For example, 28 is divided by 2 (exactly 14 times) and gives a remainder of 0. In the example, the function IF (IF) returns “Even”, i.e. “Even”.
=IF(MOD(A2,2)=0,"Even","Odd")
=ЕСЛИ(ОСТАТ(А2;2)=0;"Четное";"Нечетное")
- Odd integers divided by 2 always leave a remainder of 1. For example, 29 is divided by 2 (14 times) and gives a remainder of 1. In the example, the function IF (IF) returns “Odd”, i.e. “Odd”.