What's the difference between long and long int?
Similarly, what's the difference between short and short int?
When I use typeid on them (using visual c++) they retain their types as 'long' and 'short' instead of being converted implicitly to 'long int' or 'short int' as I thought they would have.
output: longCode:long var = 5.5; std::cout << typeid(var).name();
long and short also occupy the same amount of space as long int and short int accoring to sizeof().
So really how are they different, and why are long and short valid types when they're supposed to be modifiers? It's juzt confusing. Because I remember seeing long in examples (now forgotten where I saw them) and always thought that it was implicitly long int.
I tried searching the web for a long time but didn't get any proper material about this.