Where Can i found information on determining the largest positive, whole value that a int, unsigned int, long, unsigned long, float, and double can hold?
Where Can i found information on determining the largest positive, whole value that a int, unsigned int, long, unsigned long, float, and double can hold?
In limits.h.
Naturally I didn't feel inspired enough to read all the links for you, since I already slaved away for long hours under a blistering sun pressing the search button after typing four whole words! - Quzah
You. Fetch me my copy of the Wall Street Journal. You two, fight to the death - Stewie
Code:#include <iostream> #include <limits> using namespace std; int main(void) { numeric_limits<double> doubleLim; cout<<doubleLim.max()<<endl; cout<<numeric_limits<double>::is_signed; //...etc }
"Think not but that I know these things; or think
I know them not: not therefore am I short
Of knowing what I ought."
-John Milton, Paradise Regained (1671)
"Work hard and it might happen."
-XSquared
does not compile in linux
Code:#include <iostream> #include <limits> using namespace std; int main(void) { numeric_limits<double> doubleLim; cout<<doubleLim.max()<<endl; cout<<numeric_limits<double>::is_signed;
Show us the errors. Our psychic abilities do have limits. And you might want to add an } at the end.
Naturally I didn't feel inspired enough to read all the links for you, since I already slaved away for long hours under a blistering sun pressing the search button after typing four whole words! - Quzah
You. Fetch me my copy of the Wall Street Journal. You two, fight to the death - Stewie