c macros

Solutions on MaxInterview for c macros by the best coders in the world

showing results for - "c macros"
Sara
19 Feb 2020
1#define PRINT(x) std::cout << x << std::endl
Noely
24 Mar 2016
1/* 
2Every time the program encounters circleArea(argument),
3it is replaced by (3.1415*(argument)*(argument)).
4*/
5#define circleArea(r) (3.1415*(r)*(r))
Wesley
23 Mar 2020
1A macro is defined at the top of your program.
2for eg: #define PI 3.14
3Now whenever you write PI in your program 'PI' is replaced by 3.14
4Actually this replacement is done by the preprocessor before the source code is compiled.
5
similar questions
queries leading to this page
c macros