C++ data types


In C++, there are several built-in data types available for use
Integer Types
used to store whole numbers. They include:int: a signed integer type that can store values from -2147483648 to 2147483647.short: a signed integer type that can store values from -32768 to 32767.
long: a signed integer type that can store values from -2147483648 to 2147483647.long long: 
a signed integer type that can store values from -9223372036854775808 to 9223372036854775807.
unsigned int: an unsigned integer type that can store values from 0 to 4294967295.unsigned short: an unsigned integer type that can store values from 0 to 65535.unsigned long: an unsigned integer type that can store values from 0 to 4294967295.unsigned long long: an unsigned integer type that can store values from 0 to 18446744073709551615.

Floating poin data types
used to store decimal values. They include:float: a single-precision floating-point type that can store values from 1.17549e-38 to 3.40282e+38 with a precision of 6 decimal places.

double: a double-precision floating-point type that can store values from 2.22507e-308 to 1.79769e+308 with a precision of 15 decimal places.
long double: an extended-precision floating-point type that can store values with higher precision than double.

Character Types

used to store individual characters. They include:char: a character type that can store a single character.wchar_t: a wide character type that can store a wider range of characters.char16_t: a 16-bit character type that can store Unicode characters.char32_t: a 32-bit character type that can store Unicode characters.

Boolean Type

used to store true or false values. The bool type can store either true or false.

Void Type

 used to represent the absence of a value. The void type is typically used to indicate that a function returns no value.

In addition to these built-in data types, you can also create your own custom data types using structures, classes, and enums.