Question: Given code below need correct output. Help ME ASAP FAST Question code file So need this answer main.c 1 #include 2 3 4 int f1(

Given code below need correct output. Help ME ASAP FAST

Question code file

Given code below need correct output. Help ME ASAP FAST Question code

file So need this answer main.c 1 #include 2 3 4 int

So need this answer

f1( char var ) 5-{ 6 char fn[]="[f1]"; 7 int return_val=1; HNM

main.c 1 #include 2 3 4 int f1( char var ) 5-{ 6 char fn[]="[f1]"; 7 int return_val=1; HNM in N000 printf("%s: input is: %c and returns %2d ", fn, var, return_val ); 10 11 return return_val; 12 } 13 14 int f2( char var ) 15- { 16 char fn[]="[f2]"; 17 int return_val=2; 18 19 printf("%s: input is: %c and returns %2d ", fn, var, return_val ); 20 21 return return_val; 22 } 23 24 int f3( char var ) 25- { 26 char fn[]="[13]"; 27 int return_val=3; 28 29 printf("%s: input is: %c and returns %2d ", fn, var, return_val ); 30 31 return return_val; 32 } 33 mmmm , int main() { 1: Declare an ARRAY of 3 chars initialized to contain 3 chars 'b' and 'C' name the array "carray" ("c" is for char). char carray[4] {'a', 'b', 'c', '10'}; // 1: REPLACE the print statement below with array declaration printf("1: TODO: Add declaration of -- an array of 3 chars --- : "); 2: Declare ARRAY of function pointers below - where each function : takes one 'char' input argument and returns an 'int' as reference the below function declaration: void (*ptr_func)(int); where: *ptr_func is a ptr to a function that returns 'void' with one 'int' argument You -- need to think on how the array is initialized // // 2: add declaration below: printf("2: TODO: Add declaration of -- an array of function ptrs--- : "); 3: // call each of the functions by iterating through // the array declared in 2, with input from // from carray (iterating through the array declared // in 1). i.e: // first iteration f1 with input carray item @ second iteration f2 with input carray item 1 // third iteration f3 with input carray item 2 // insert the call inside the while Loop below. int c = 0; while( c

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!