Possible Duplicate:
What is the difference between an int and a long in C++?
difference in long vs int data types in C++
In c++ which is the diference between the int and long data type. Wrote the following code:
int _tmain(int argc, _TCHAR* argv[])
{
cout<<"Int_Max = "<<INT_MAX<<endl;
cout<<"Int_Min = "<<INT_MIN<<endl;
cout<<"Long_Max = "<<LONG_MAX<<endl;
cout<<"Long_Min = "<<LONG_MIN<<endl;
}
And this were the results...
Int_Max = 2147483647
Int_Min = -2147483648
Long_Max = 2147483647
Long_Min = -2147483648
I'm confused.