double sqrt (double x);
double sqrt (double x); float sqrtf (float x);long double sqrtl (long double x);
double sqrt (double x); float sqrt (float x);long double sqrt (long double x);
double sqrt (double x); float sqrt (float x);long double sqrt (long double x); double sqrt (T x); // additional overloads for integral types
<cmath>
)为整数类型提供了其他重载:这些重载在计算前有效地将 x 转换为 double
(为 T 是任何整数类型的情况定义)。<complex>
和 <valarray>
中进行了重载(请参阅 complex sqrt 和 valarray sqrt)。
|
|
sqrt(1024.000000) = 32.000000 |