Explain what are the uses of the keyword static?

Submitted by: Muhammad
Static keyword can be used with variables as well as functions. A variable declared static will be of static storage class and within a function, it maintains its value between calls to that function. A variable declared as static within a file, scope of that variable will be within that file, but it can't be accessed by other files.

Functions declared static within a module can be accessed by other functions within that module. That is, the scope of the function is localized to the module within which it is declared.
Submitted by: Muhammad

Read Online Embedded Software Engineer Job Interview Questions And Answers