Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
重複の可能性: 12の累乗でdouble値を上げる方法は? 10.パワー/計算/パワー計算
iPhoneのオブジェクトCで、x ^ yをどのように計算しますか?スタックをポップして値を取得する
あなたがする必要が#include <math.h>あり、その後あなたは使用することができます
#include <math.h>
double res=pow(10, 1.5);
pow(x、y)を使用できます。
double値を返します。
整数にキャストするには、myPowerNum =(int)pow((double)x、(double)y);