C program code
int zap(int n)
{
if(n<=1)then zap=1;
else zap=zap(n-3)+zap(n-1);
}
then the call zap(6) gives the values of zap
[a] 8 [b] 9 [c] 6 [d] 12 [e] 15
Answer Posted / madhu
if (n<=1)
zap = 1;
it gives a compile time error invlaid l value assignment.
zap is a function and cannot be assigned a value
| Is This Answer Correct ? | 1 Yes | 6 No |
Post New Answer View All Answers
How can I automatically locate a programs configuration files in the same directory as the executable?
Why is c so important?
What does sizeof function do?
What are the storage classes in C?
Write a progarm to find the length of string using switch case?
What is declaration and definition in c?
What is auto keyword in c?
Write a Program to accept different goods with the number, price and date of purchase and display them
When can a far pointer be used?
What is data structure in c programming?
write a sorting prgm to sort 50 nos and sum them and also remove all the occurrences of 15 and print it?
How can you increase the allowable number of simultaneously open files?
Differentiate between Macro and ordinary definition.
What will the preprocessor do for a program?
What does %d do?