/************************************************************************ * * * Program: HoursToMins.cpp * * * * Author: Robb T. Koether * * * * Date: Sep 9, 2003 * * * * Purpose: This program will convert a decimal number of hours * * to a whole number of minutes * * * ************************************************************************/ // Header files #include #include using namespace std; /************************************************************************ * * * Function: main * * * * Purpose: To convert a decimal number of hours to a whole number * * of minutes * * * ************************************************************************/ int main() { // Get the decimal number of hours from the user cout << "Enter the number of hours: "; float hours; cin >> hours; // Find the number of minutes int mins = 60 * hours; // Print the result cout << "The number of minutes is " << mins << endl; return 0; }