question archive Using C++ Complete the function definition to output the hours given minutes

Using C++ Complete the function definition to output the hours given minutes

Subject:Computer SciencePrice:2.85 Bought3

Using C++

Complete the function definition to output the hours given minutes. Output for sample program:

3.5

Given Code

#include <iostream>
using namespace std;

void OutputMinutesAsHours(double origMinutes) {

/* Your solution goes here */

}

int main() {

OutputMinutesAsHours(210.0); // Will be run with 210.0, 3600.0, and 0.0.
cout << endl;

return 0;
}

pur-new-sol

Purchase A New Answer

Custom new solution created by our subject matter experts

GET A QUOTE

Answer Preview

#include <iostream>
using namespace std;

void OutputMinutesAsHours(double origMinutes) {

/*conversion of minutes to hours */
double hours = origMinutes / 60.0;
cout<<"The number of Hours for the given minutes :"<<hours<<endl;
}

int main() {
OutputMinutesAsHours(3600.0); // Will be run with 210.0, 3600.0, and 0.0.
cout << endl;
return 0;
}

please see the attached file for complete solution