Optimization: only iterate over odd numbers.
It can not be divided by even numbers because no odd number can.