Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What kind of data type is "long long"?

I don't know this type. Is that the biggest one from all? I think it is an integer type, right? Or is it a floating point thing? Bigger than double?

like image 604
openfrog Avatar asked Jan 24 '10 15:01

openfrog


People also ask

What data type is long long?

LongLong (LongLong integer) variables are stored as signed 64-bit (8-byte) numbers ranging in value from -9,223,372,036,854,775,808 to 9,223,372,036,854,775,807. The type-declaration character for LongLong is the caret (^). LongLong is a valid declared type only on 64-bit platforms.

What is long long type in C?

According to C99 standard, long long is an integer type which is at least 64-bit wide. There are two integer 64-bit types specified: long long int and unsigned long long int. So, yes, this is the biggest integer type specified by C language standard (C99 version).

What is long long int?

A long int is a signed integral type that is at least 32 bits, while a long long or long long int is a signed integral type is at least 64 bits. This doesn't necessarily mean that a long long is wider than a long . Many platforms / ABIs use the LP64 model - where long (and pointers) are 64 bits wide.

WHAT IS LONG datatype used for?

Remarks. Use the Long data type to contain integer numbers that are too large to fit in the Integer data type. The default value of Long is 0.


1 Answers

According to C99 standard, long long is an integer type which is at least 64-bit wide. There are two integer 64-bit types specified: long long int and unsigned long long int

So, yes, this is the biggest integer type specified by C language standard (C99 version).

There is also long double type specified by C99. It's an extended precision floating point numeric data type long for 80-bits on most popular x86-based platforms and implementations of C language.

like image 128
mloskot Avatar answered Oct 19 '22 13:10

mloskot