having a hard time with getting the write code for calculating time???

I’m a beginner with solving problems in C++, and I’m having a hard time for getting the right code of calculating time. I’m trying to

1. Prompt the user to enter in a starting time in 24 hour format
2. Get the user input as a single integer
3. Prompt the user to enter in an ending time in 24 hour format
4. Get the user input as a single integer
5. Calculate the new ending time
6. Print out the new ending time

I would really be grateful if somebody can help me.


Please have a go at it first, we are not here to do your home work.

Take a look at the header time.h to see some functions that handle time/date.
Last edited on
maxemo, what would you need to have done to "Calculate the new ending time"?

I mean, you want them to be averaged, subtracted or what?
Topic archived. No new replies allowed.