âGood Morning! said Bilbo, and he meant it. The sun was shining, and the grass was very green. But Gandalf looked at him from under long bushy eyebrows that stuck out further than the brim of his shady hat.
C / C++ / VC++ / MFC Interview Questionsâ > âCâ > âFrequently Asked Questionsâ > â. static is an access qualifier that limits the scope but causes the variable to exist through out the lifetime of the program.
A static variable is a special variable that you can use in a function, and it saves the data between calls, and it does not delete it between calls. For example: void func(){ static int count; // If you don't declare its value, the value automatically initializes to zero printf(%d, , count); count++; } void main(){ while(true){ func(); } }