Folks, as the global or static variables are stored in data section of process and their scope is throughout the program, but once the main() function returns or complete execution or when whole program is executed and activation record of main() is also popped off from stack, but then what happens to that data section?
Does global variable stays or the whole process is deleted including global variables from memory once the program ran to completion?