Question 9490 – C-Programming
November 11, 2023
Question 9521 – C-Programming
November 11, 2023
Question 9490 – C-Programming
November 11, 2023
Question 9521 – C-Programming
November 11, 2023

Question 9519 – C-Programming

Consider the following C function:

     int f(int n)
     {
        static int i = 1;
        if (n >= 5)
           return n;
        n = n+i;
        i++;
        return f(n);
     } 

The value returned by f(1) is

Correct Answer: C

Question 8 Explanation: 

The value return by f(1) = 7
A
5
B
6
C
7
D
8
0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
error: Alert: Content selection is disabled!!