What will be the output of the following C code? [code]#include<stdio.h> main() { int n=10; int f(int n); printf("%d",f(n)); } int

What will be the output of the following C code?
Code:
#include<stdio.h>
main()
{
    int n=10;
    int f(int n);
    printf("%d",f(n));
}
int f(int n)
{
    if(n>0)
        return(n+f(n-2));
}
A. 10
B. 80
C. 30
D. Error
 

Tìm kiếm

Back
Top