Execution of Preprocessor Directives

I want to know about when the preprocessor directives actually execute?
Either they execute before the compiler compiles our program or after the compiler compiles our program,or at the same time the compiler compiles our program?

Explain the answer with logics so that i would be cleared in my concepts...
pre-> before

#include
#pragma comment
# pragma message
#pragma once
#ifdef
#ifndef
#undef
#else
#endif

etc
You can safely assume that any line starting with # is handled by the preprocessor.
Topic archived. No new replies allowed.