These are the most commonly used built-in types:
int: whole numbersfloat, double: decimal numberschar: single character (enclosed in single quotes)bool: true or falseint age = 25;
float price = 19.95;
char grade = 'A';
bool isPassed = true;Modifiers adjust size or behavior:
short, long, long longunsigned → positive values onlyunsigned int u = 42;
long long big = 900000000000LL;Use the string type for text (requires #include <string>):
string name = "Alice";Use sizeof() to check how much memory a type uses:
cout << sizeof(int); // 4 (typically)
cout << sizeof(double); // 8C++ supports implicit and explicit type conversions:
int a = 10;
double b = a; // implicit
int c = (int)b; // explicit castauto lets the compiler deduce the type:
auto score = 95; // int
auto name = "Bob"; // const char*Ask the AI if you need help understanding or want to dive deeper in any topic