_pow(float x, float y)
how can I do this? It is easy with the integer powers with recursion but how can I get 2^(0.125) for example.
I don't want to use cmath
An integer cannot handle exponents. use float or double
a^b = c
b ln(a) = ln(c)
exp( b ln(a) ) = c
You could use Taylor for the logarithm.
Topic archived. No new replies allowed.