An object represents a region in the storage (RAM or CPU registers) that can be used to store values. In c++, we usually access memory indirectly through these objects instead of direct memory access.
Usually, an object can refer to unnamed objects, variables and functions. However in c++, functions are excluded.
A named object is called a variable. Each variable has an identifier (such as person_name, age etc.), data type (or just type) and value. Data type specify how much storage is required to store the value.
A variable can be declared in c++ as follows,
int a;
double b;When compiler encounters these statements, it makes storage available for these variables in memory.