Question: Write a C++ code that gets a number of minutes from the user and translates it into time on a 12 hours clock. If the

Write a C++ code that gets a number of minutes from the user and translates it into time on a 12 hours clock. If the user puts 0 minutes into the program the program should output the string "0:0 !". The number before the colon is the number of hours, the number after the colon is the number of minutes. Here are some more examples of input and output: Input: "60" --> Output: "1:0 !" Input: "121" --> Output: "2:1 !" Input: "785" --> Output: "1:5 !" // Notice the 12 hour clock time adjusts 13 hours to 1 hour.

No if or statements allowed.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!