What is the difference in use of define and const variable?

1.type checking in const that is not a part of #define. 2.scope 3.debugging is possible with const.

const variable can be localized whereas #define variable cannot be done so.

#define simply replaces whatever you have defined by the text you want it to replace.

const variable's value cannot be manipulated during the course of the program.

#define is a text preprocessor command and like all text preprocessor commands (beginning with "#") are handled by textual substitution throughout the code before the compiler sees any of the code.

const is a compiler keyword that identifies a constant declaration. It is handled by the actual compiler.