How to avoid floating point math

ahem...what's a code tag?
Ok got it. Revised. Thanks