Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- int main()
- {
- const int secInMin{ 60 };
- int sec{ 75 };
- int min{ 0 };
- std::cout << " Enter seconds: ";
- std::cin >> sec;
- min = sec / secInMin;
- sec %= secInMin;
- std::cout << min << ":" << sec << '\n';
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment