Eight-Byte Data Types

Eight-Byte Data Types

I am looking for a data type in C++ that takes eight bytes. I have tried long, long int, and so forth, but they are all four bytes on Windows NT. I need an eight-byte integer datatype for some encryption algorithm. Could you tell me what to do?

Standard C++ does not define an eight-byte integer type. However, this situation will change pretty soon, because C9X (the new C draft standard) now defines the “long long” data type, which is a 64-bit integer.

In practice, most C++ compilers already define a non-standard integer type that holds eight bytes. Visual C++, for instance, defines __int64 and __uint64 for signed and unsigned eight-byte integers, respectively. You can use these types on Windows NT.

See also - an AI reverse image search platform

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