Page 1 of 1
Write a suitable C Program to accomplish the following tasks. Task 1: Find the error in each of the following program se
Posted: Tue Apr 12, 2022 10:25 am
by answerhappygod

- Write A Suitable C Program To Accomplish The Following Tasks Task 1 Find The Error In Each Of The Following Program Se 1 (30.09 KiB) Viewed 36 times

- Write A Suitable C Program To Accomplish The Following Tasks Task 1 Find The Error In Each Of The Following Program Se 2 (18.59 KiB) Viewed 36 times
Write a suitable C Program to accomplish the following tasks. Task 1: Find the error in each of the following program segments and Explain how the error can be corrected run the script to check the answer 1- int g(void) { printf("%s", Inside function g\n"); int h(void) { printf("%s", Inside function h\n"); } 1 2- 2. void f(float a); { float a; printf("%f", a); } 3- int sum(int n) { if (0 == n) { return 0; // } else { n + sum(n-1): } }
4- void product(void) { printf("%s", "Enter three integers: ") int a, b, c; scanf("%d%d%d", &a, &b, &c); int result = a * b* C; printf("Result is %d", result); return result; }