A.C
func()
{
pritnf(" in fuction %d",MACRO);
}
MAIN.c
testfunc()
{
#define MACRO 10
printf("in test function %d", MACRO);
}
main()
{
printf("in main %d",MACRO);
func();
testfunc();
getch();
}
Answer Posted / modassir
The error is for the line where we try to call func()
where we try to print macro through printf, as because
macro is not define there.
Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
List the difference between a "copy constructor" and a "assignment operator"?
Write a code to remove duplicates in a string.
What is the purpose of main() function?
what is the difference between class and unio?
What are operators in c?
What do you mean by keywords in c?
What does c mean before a date?
Can we declare variable anywhere in c?
Explain what is a const pointer?
What is the meaning of c in c language?
‘SAVEPOINT’ and ‘ROLLBACK’ is used in oracle database to secure the data comment. Give suitable examples of each with sql command.
Tell us the use of fflush() function in c language?
How are Structure passing and returning implemented by the complier?
Write a program to use switch statement.
What are c identifiers?