In what situations we need to use .h
file and when to use the .c
file in C.
Are they two alternatives for a same purpose?.
Please explain.
Whenever you feel tempted to include a .c file, you instead want to add it to your project so that it gets processed during building, i.e. gets compiled by its own and in a further build step gets linked into the created binary.