Question: In C++ code please Write a function that verifies if a given number exists in an array of floats. The function is supposed to return

In C++ code please Write a function that verifies if a givenIn C++ code please

Write a function that verifies if a given number exists in an array of floats. The function is supposed to return the first position in where the number is encountered. If the given number does not exist, the function returns -1.Then write a program that asks the user to enter an array of floats and calls the function. The prototype of the function should be like: int Search (floats al I, int n, float number) Example: Consider the following array of floats 211 9 -14 17.3 5.9 9 17 0 If the number to be searched is 5 4 the function returns1 If the number to be searched is 9 the function retuns 2

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!