That is the best solution, you should also check for "NumberFormatException" exceptions, just incase of non valid charecters. Then return feedback to the user if it's wrong.
If you don't want floats, your going to have to look at fixed point arthimetic. The reason they want you to avoid using float is because it's rarely implemented on phone cpu's(Probbly arm), and has to be implemented in software which is slow. Fixed point is usally surported in hardware.