Clock angle problem


Given a time string that is in the following 12-hour format (hh:mm), determine the angle between the hour and the minute hands on an analog clock. An example input and output is shown below:

Input: 12:45
Output: 112.5


Access restricted

Subscribe to premium account to see the solution.

Get premium now