In the static memory allocation, the amount of memory to be allocated is predicted and pre known. This memory is allocated during the compilation itself. All the declared variables declared normally, are allocated memory statically.
In the dynamic memory allocation, the amount of memory to be allocated is not known beforehand. It is allocated during run time as and when required. The memory is dynamically allocated using new1 operator.
The objects that are allocated memory statically have the lifetime as their scope allows, as decided by the compiler. And the objects that are allocated memory dynamically have the lifetime as decided by the programmer. That is until the programmer explicitly deallocates the memory, such objects live in the memory.