السلام عليكم ورحمة الله وبركاته ..
3 امثلة على الفنكشنز بحاجه لإجابه ..
uestion 3: Write function prototype and function definition of the function named largestValue that takes two arguments array of integer values and array size. The function should return the largest of the values in the array.
Question 6: Write a function named reverse the following prototype:
void reverse(float array[], int size);
The function must reverse the order of the values in the array. For example:
Before Reversing:
0: 5.8
1: 2.6
2: 9.0
3: 3.4
4: 7.1
After Reversing:
0: 7.1
1: 3.4
2: 9.0
3: 2.6
4: 5.8
Question 7: Write a program that read 10 values in an integer array. Then the program should replace the contents of each cell with the sum of the cell and the contents of all the cells before the current cell in the array as the following example of 5 values:
Before:
0 : 3
1: -1
2: 4
3: 7
4: -2
After:
0: 3
1: 2
2: 6
3: 13
4: 11