powered by
Checks whether x is an even or odd number. Only accepts numeric vectors.
x
is_even(x)is_odd(x)
is_odd(x)
Numeric vector or single numeric value, or a data frame or list with such vectors.
is_even() returns TRUE for each even value of x, FALSE for odd values. is_odd() returns TRUE for each odd value of x and FALSE for even values.
is_even()
TRUE
FALSE
is_odd()
# NOT RUN { is_even(4) is_even(5) is_even(1:4) is_odd(4) is_odd(5) is_odd(1:4) # }
Run the code above in your browser using DataLab