Skip to main content
Tuesday (24.11.2026) at 20:00: ALGOR Contest: Round #4 (Special Challenge) starts!

~/algor $ cat problems/soatni-12-soatlikka-otkazish

From 24-hour to 12-hour clock

Easy 1000 ms 64 MB 17%
Share

An hour $h$ is given in $24$-hour format (from $0$ to $23$). Find which number this hour shows on a $12$-hour clock face. The face has the numbers $1$ to $12$: both $0$ o'clock and $12$ o'clock show $12$, $13$ o'clock shows $1$ and $23$ o'clock shows $11$.

Hours 1 to 12 on the inner circle and 0 to 23 on the outer circle; the given hour matches a number on the inner circle

Input

One integer $h$.

Output

One positive integer from $1$ to $12$.

Note

$0 \le h \le 23$

Examples

Input #1
15
Output #1
3
Input #2
0
Output #2
12

Sign in to submit a solution

Signing up is free and takes a minute.