#P8071. [COCI 2009/2010 #7] SPAVANAC

[COCI 2009/2010 #7] SPAVANAC

Problem Description

Given a time H:MH:M in the 2424-hour format, output the time in the 2424-hour format that is 4545 minutes earlier than it.

Input Format

The first line contains two integers H,MH, M.

Output Format

Output two integers representing the time 4545 minutes earlier.

10 10
9 25
0 30 
23 45
23 40
22 55

Hint

【Constraints】

  • For 100%100\% of the testdata, 0H230 \le H \le 23, 0M590 \le M \le 59.

【Hints and Notes】

This problem is translated from COCI 2009-2010 CONTEST #7 Task 1 SPAVANAC.

The score for this problem follows the original COCI settings, with a full score of 3030.

Translated by ChatGPT 5