Given a time as two integers, hour and minutes, return the smaller angle in degrees between the hour hand and the minute hand of an analog clock. Answers within $10^{-5}$ of the true value are accepted.
Given a time as two integers, hour and minutes, return the smaller angle in degrees between the hour hand and the minute hand of an analog clock. Answers within 10−5 of the true value are accepted.
Example 1:
Input: {"hour":12,"minutes":30}
Output: 165.0
Constraints:
1≤ hour ≤12
0≤ minutes ≤59
Test Cases
Input (Stdin)
Expected Output (Stdout)
Execution Result
Run code to see results.
Input
arr ={"hour":12,"minutes":30}
The time is 12:30. Measure both hands in degrees clockwise from 12, then take the gap between them.