
C is a programming language developed by american computer scientist dennis ritchie in early 1970's that is considered as a low level language since its very close to the hardware.Its also beginner friendly and has only 32 keywords.
Before a c program is executed it is processed in stages including pre-processing,compiling,assembly and linking.
Computers understand only 0's and 1's.After a source code is done processing it produces an executable file a machine code that the computer understands well.Also a c program requires a compiler to process a source code.Mainly used is gcc compiler.
Pre-processing
This stage the compiler combines headerfiles with source code to produce an intermediate file with a extension .i which can be standard library functions and user defined libraries using the keyword #include.
Compilation
This stage converts a preprocessor file to assembly language code.This stage checks for syntax errors and other types of errors in our source code. Assembly code mainly plain english considered low level .But it needs further processing for computer to understand and results in a file with .s extension
Assembly
In this stage it converts assembly code using an assembler to machine code that computer can understand.The file produced is known as object file with a .obj extension
Linking
This stage the compiler add necessary library files that has functions for machine code and our object file so that computer understand our predefined words used in our code its like a dictionary where it searches for keywords it doesnt know. This stage produces a executable file with an .out extension in UNIX operating system.Which the computer can know understand and give us output we want.




