Question - In C, what is the difference between a static variable and global variable?
Answer -
A static variable declared outside of any function is accessible only to all the functions defined in the same file (as the static variable). However, a global variable can be accessed by any function (including the ones from different files).