You were right about his number, but that's not really C++, that's just basic logic. You could understand that and correct it. (And just to back you up, if you had posted that code, I would have said something, his code was a suggestion. If you want to post functions that you have completed that you're not sure are correct, I'll review them for you.)
in displayTime() you need to do something so that 5 hours and 5 minutes displays as 05:05 and not 5:5
Maybe you should print the tens digit and the ones digit of each number. If you don't understand that, you could look into "iomanip, setfill and setw".
In elapsed(), realize that t1 is the 'start' time and t2 is the 'end' time, and think back to your basic math:
- How much time has elapsed between 08:45 and 10:15?
- How did you figure out that it was 01:30?
- Make the computer do that...