Advertisement
DMG

Emisija

DMG
Mar 7th, 2013
61
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.37 KB | None | 0 0
  1. /* http://www.hsin.hr/skolska2007/zadaci/bas_pas/druga/zadaci.pdf */
  2. #include <iostream>
  3. using namespace std;
  4. main()
  5. {
  6.       int h, m, t;
  7.       cin >> h >> m >> t;
  8.      
  9.       int p = m + t;
  10.      
  11.       while (p>59)
  12.       {
  13.             h = h + 1;
  14.             p = p - 60;
  15.       }
  16.      
  17.       cout << h << ":" << p << endl;
  18.      
  19.       system ("PAUSE");
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement