Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int x1, x10, x60, rides;
- cin >> rides;
- x60 = rides/60;
- if ((rides % 60) >= 35)
- {
- x60 = x60 + 1;
- }
- else
- {
- x10 = (rides % 60)/10;
- if ((rides%60)%10 = 9)
- {
- x10 = x10 + 1;
- }
- else
- {
- x1 = (rides%60)%10;
- }
- }
- cout << x1 << x10 << x60;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement