That looks fine, what's the problem?
You probably need
#include <math.h>
or similar, is all.
<edit>
The other thing you need to know is that C++ is a strongly-typed language, whereas BASIC, including Blitz, and C are weakly-typed.
What do this mean?
It means that you need to *tell* the compiler the types of things instead of the compiler using some other built-in rule set.
So, if you go:
int a=5;
double b = sqrtf(a);
It might not work for you.
In BASIC, it would automatically make 'a' into a float, and then make the float result into a double.
C would do something similar, but different.
C++ doesn't. It will say that there is no implementation of sqrtf that takes an int parameter and returns a double.
You would need to write
double b = (double)sqrtf((float)a);
Jim