isOdd property

bool isOdd

Checks if the number is odd. Returns true if the number is not evenly divisible by 2, otherwise false.

Implementation

bool get isOdd => !isEven;