Question: What is the cror in the following code segment? Aindudestidiohs Eincludermathho float exam function(fioat a foat b) float e casqrt(a*b) retum c 1 int mainy




![following program segments and correct the errors. a. int x[5]={1,2,3,4,5}; for (](https://s3.amazonaws.com/si.experts.images/answers/2024/09/66e1b1b54c1e9_12466e1b1b48c250.jpg)


![put. b. char si [20]="End of semester": char s2[20]="2019-2020_" char s3[20]="": char](https://s3.amazonaws.com/si.experts.images/answers/2024/09/66e1b1b7e9bf6_12766e1b1b7597dd.jpg)
What is the cror in the following code segment? Aindudestidiohs Eincludermathho float exam function(fioat a foat b) float e casqrt(a*b) retum c 1 int mainy ffloat x,y. printifenter x and y ") scanf "tfoff box sy): refurn (x : Q1. Find the error in each of the following program segments and correct the errors. a. int x[5]={1,2,3,4,5}; for ( in ti=0;i0) printf("\%d",d-): e. for (int k=10;k>5;k++) printf( ("%d,k2) Determine the output of the following C program segments below. You must show all the put. b. char si [20]="End of semester": char s2[20]="2019-2020_" char s3[20]="": char s4[20]= "End of smtr" printf("\%s",strcat (s2,s1)) : printf("\%s", strncpy(s3,s2,13)): printf("\%d", stremp(s1, s4)): c. int n=1,c=0,a[5]={9,4,12,1,8}; while (n0); printf("Rev is \%d",rev); if ( val == rev) printf("equal "); else printf("no "); e. void f() : int main() \{ f() : return 0; \} void f() \{int l=1: ++1; printf((") is \%d",): It+; printf("I is \%d".1): printf("l is \% d,1++) : printf(") is \%d". 1++); printf(" " is \%d", 1) : \} f. \#include
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
