Data Type Modifiers

Get introduced to data type modifiers.

Introduction #

The maximum value that can be stored in a variable of type int is 2147483647. What if we want to store a value greater than 2147483647?

Run the code below and see the output!

Press + to interact
#include <iostream>
using namespace std;
int main() {
// Initialize variable
int number = 2147483649;
// Display variable value
cout << number;
}

If we run the code given above, it does not give us the expected output. The above code should print 2147483649, but it is printing -2147483647 in output. So how can we handle values greater than the range of a data ...