uniform_real Class
產生一致的浮點散發。 保留為 TR1 相容性。 使用 uniform_real_distribution 。
template<class RealType = double>
class uniform_real {
public:
typedef RealType input_type;
tpyedef RealType result_type;
explicit uniform_real(result_type min0 = result_type(0), result_type max0 = result_type(1));
result_type min() const;
result_type max() const;
void reset();
template<class Engine>
result_type operator()(Engine& eng);
private:
result_type stored_min; // exposition only
result_type stored_max; // exposition only
};
參數
- RealType
浮點結果型別。
備註
樣板類別描述會產生使用者定義的浮點型別的值與統一散發的散發。
需求
標題: <random>
命名空間: std