/*	Time Conversion program with prototypes */

#include <iostream.h>

using namespace std;	// October 5, 2001

//--------------------------------------------------------------------------------
void DaysToHours();
/* Converts days to hours */
void HoursToDays();
/* Converts hours to days */

//--------------------------------------------------------------------------------
int main()
{
	char Choice;
	cout << "1  Days to Hours" << endl;
	cout << "2  Hours to Days" << endl;
	cout << "Enter your choice: ";
	cin >> Choice;
	if (Choice == '1')
		DaysToHours();
	else
		HoursToDays();

	return(0);
}
//--------------------------------------------------------------------------------
void DaysToHours()
/* Converts days to hours */
{
	int Days, Hours;

	cout << "Enter the number of days: ";
	cin >> Days;

	Hours = Days*24;
	cout << "The number of hours in " << Days << " days is: " << Hours;
}
//--------------------------------------------------------------------------------
void HoursToDays()
/* Converts hours to days */
{
	int Hours, Days;

	cout << "Enter the number of hours: ";
	cin >> Hours;

	Days = Hours/24;
	cout << "The number of days in " << Hours << " hours is: " << Days;
}

