If you want to execute C program even after main function is terminated, which function can be used?

C Programming Language >   Function in C Language >   Predefined Functions  

Short Question

875


Answer:

  • atexit() function can be used if we want to execute any function after program is terminated normally.
  • Syntax: int atexit (void (*func)(void));
  • The function “func” will be called automatically without any arguments once program is terminated normally.


This Particular section is dedicated to Question & Answer only. If you want learn more about C Programming Language. Then you can visit below links to get more depth on this subject.




Join Our telegram group to ask Questions

Click below button to join our groups.