Sale!

Lab #1 CS-2050 – Section B

$30.00 $18.00

Category: You will Instantly receive a download link for .zip solution file upon Payment || To Order Original Work Click Custom Order?

Description

5/5 - (5 votes)

1 Requirements
This lab is intended to test your ability to pass variables by reference, and is also a review of file IO.
1.1 main
You are provided with a partially completed main function, which you must finish.
Info: The main function of this program reads test data from a file into an array, and then passes the
data to a function for analysis. The file IO portion of the program has been provided as starter code,
and you must write the function call in order to complete the main() function.
i
1.2 maxBelow
int maxBelow ( float * array , int size , float * result , int ceiling ) ;
Info: This function takes a float array and the size of the array as parameters, and searches the array
for the maximum number in the data that is less than the provided ceiling. The function returns 1
on success and 0 if the data does not contain a number smaller than the provided ceiling. The result
of this analysis must be placed into the result variable.
i
2 Notice
Grading:
1. Complete main function
* 3 points
2. Write required function: maxBelow
* 5 points
!
Notice:
1. All of your lab submissions must compile under GCC using the −W all and −W error flags to be
considered for a grade.
2. You are expected to provide proper documentation in every lab submission, in the form of
code comments. For an example of proper lab documentation and a clear description of our
expectations, see the lab policy document.