numeric_limits::min_exponent
傳回浮點型別可以表示為限制值的最大負數整數的指數,當基底對數 (即引發該電源時。
static const int min_exponent = 0;
傳回值
最小整數的以基數的指數能由型別。
備註
成員函式的浮點型別才有意義。 min_exponent 是型別的 float值 FLT_MIN_EXP。
範例
// numeric_limits_min_exponent.cpp
// compile with: /EHsc
#include <iostream>
#include <limits>
using namespace std;
int main( )
{
cout << "The minimum radix-based exponent for type float is: "
<< numeric_limits<float>::min_exponent
<< endl;
cout << "The minimum radix-based exponent for type double is: "
<< numeric_limits<double>::min_exponent
<< endl;
cout << "The minimum radix-based exponent for type long double is: "
<< numeric_limits<long double>::min_exponent
<< endl;
}
需求
標題: <limits>
命名空間: std