Type: Default 1000ms 256MiB

时钟刻度

You cannot submit for this problem because the contest is ended. You can click "Open in Problem Set" to view this problem in normal mode.

题目描述

众所周知,常见时钟有 1212 个数字 1121\sim 12

假设当前时钟的时针恰好指向数字 aa,请问最少过几个小时后,时针将恰好指向数字 bb(题目保证 aba\neq b)。

输入格式

空格隔开的两个整数 a,ba,b

输出格式

一个整数,即最少的小时数。

3 9
6
11 4
5
12 8
8

数据规模与约定

  • 对于 60%60\% 的数据:a<ba\lt b
  • 对于 100%100\% 的数据,1a,b121 \le a,b \le 12aba\neq b

2025 练习赛 2

Not Attended
Status
Done
Rule
IOI
Problem
7
Start at
2025-10-25 0:00
End at
2025-10-27 0:00
Duration
48 hour(s)
Host
Partic.
26