← Back to question

Answer explained

What is a static variable?

A static variable exists for the program's lifetime. A local static is initialized once and retains its value between calls; a static data member is shared by all objects.