What is the sequence of function execution of the above statement. 1. printf, f1(), f2() 2. printf, f2(), f1() 3. f1(), f2(), printf 4. f2(), f1(), printf.
Let's understand this by going through the following code
#include<stdio.h> int f1(); int f2();
void main() { printf(" dt d" f1() f2()); }
int f1() { printf("f1() enteredn"); return 4; }
int f2() { printf("f2() enteredn"); return 5; }
O/P-
f2() entered f1() entered 4 5
we can conclude f2() is 1st executed then f1() and in the end printf().hence we can say the precedence of execution of functions are from right to left.