What is macro?
Answers were Sorted based on User's Feedback
Answer / jayasrinivas.donavalli
macro is a subroutine.
Need of Macro: Some times there is a need to call the set
of codedata again and agian in the program.In that
particular situation we can use macros.
Use of Macro can increase the efficiency of the program and
also decrease the length of the code.
Macro can be defined by using Define statement
| Is This Answer Correct ? | 8 Yes | 0 No |
Answer / nagendranath.s
A macro is used to define a short functional code where it
can be inserted in a number of places(where the functional
code is compiled more than once)
| Is This Answer Correct ? | 2 Yes | 1 No |
Answer / kesar
Macro is define by user
it locks the lot modifications....
Example:
int a[2000];
If you use lot of places 2000 in your code
some time you want to change the 2000 to 500
then you must replace 2000 with by 500. this changes are
repeatedly by u....
In this case if you define macro
Just you change the macro it will effect over all program..
| Is This Answer Correct ? | 1 Yes | 0 No |
Answer / rohit
macro is a subroutine.
A macro is used to define a short functional code where it
can be inserted in a number of places(where the functional
code is compiled more than once)
Need of Macro: Some times there is a need to call the set
of codedata again and agian in the program.In that
particular situation we can use macros.
Use of Macro can increase the efficiency of the program and
also decrease the length of the code.
Macro can be defined by using Define statement
Example:
int a[2000];
If you use lot of places 2000 in your code
some time you want to change the 2000 to 500
then you must replace 2000 with by 500. this changes are
repeatedly by u....
In this case if you define macro
Just you change the macro it will effect over all program..
| Is This Answer Correct ? | 1 Yes | 0 No |
Where local variables are stored in c?
9.how do you write a function that takes a variable number of arguments? What is the prototype of printf () function? 10.How do you access command-line arguments? 11.what does ‘#include<stdio.h>’ mean? 12.what is the difference between #include<> and #include”…”? 13.what are # pragma staments? 14.what is the most appropriate way to write a multi-statement macro?
Is main is a keyword in c?
Why is it that not all header files are declared in every C program?
How would you find a cycle in a linked list?
What’s the special use of UNIONS?
write a c program to do the following: a) To find the area of a triangle. b) To convert the temperature from Fahrenheit to Celsius. c) To convert the time in hours : minutes : seconds to seconds.
What is the difference between void main and main in c?
What is static and volatile in c?
Write a C program to multiply tho numbers without using arithmetic operator (+, -, *, /).
what are the advantage and disadvantage of recursion
What are inbuilt functions in c?