devxlogo

The New long long Data Type

The New long long Data Type

The long long type denotes an integral data type that is at least as large as a long int. On 32-bit architectures and 64-bit architectures, long long occupies 64 bits (eight bytes). Although long long is not defined by theANSI/ISO C++ standard yet, it is defined by the C9X draft standard and in practice, many platforms (Win32, Unix, Linux and others) already support it. As with other integral types, a long long can also be unsigned:

   unsigned long long distance_to_star;

You can add the affixes “ll” and “LL” to a literal integer to indicate a long long type:

   #define year_light_in_km 9460800000000LL

Similarly, you can add the affixes “ull” and “ULL” to a literal integer to indicate an unsigned long long type.

devxblackblue

About Our Editorial Process

At DevX, we’re dedicated to tech entrepreneurship. Our team closely follows industry shifts, new products, AI breakthroughs, technology trends, and funding announcements. Articles undergo thorough editing to ensure accuracy and clarity, reflecting DevX’s style and supporting entrepreneurs in the tech sphere.

See our full editorial policy.

About Our Journalist