Reputation: 24685
In what header is max value for double defined?
Upvotes: 1
Views: 6994
Reputation: 18905
#include <limits>
int main()
{
std::cout << "Maxvalue for double: " << std::numeric_limits<double>::max();
return 0;
}
Upvotes: 19
Reputation: 2171
On my system (VS 10) it's float.h. The define is DBL_MAX 1.7976931348623158e+308
Upvotes: 3
Reputation: 4805
If you're using C++ the standard way of achieving this is with:
#include <limits>
std::numeric_limits< double >::max();
Upvotes: 11
Reputation: 3446
If you are working with VS, you can see this link: http://msdn.microsoft.com/en-us/library/s3f49ktz.aspx
Upvotes: 0