Given the time in numerals we may convert it into words, as shown below:

5:00→ five o' clock

5:01→ one minute past five

5:10→ ten minutes past five

5:30→ half past five

5:40→ twenty minutes to six

5:45→ quarter to six

5:47→ thirteen minutes to six

5:28→ twenty eight minutes past five

Write a program which prints the time in words for the input given in the format mentioned above.

Input Format

There will be two lines of input:

H, representing the hours

M, representing the minutes

Constraints

1≤H≤12

0≤M<60

Output Format

Display the time in words.

SAMPLE INPUT
5  
47

SAMPLE OUTPUT
thirteen minutes to six
h=int(raw_input())
m=int(raw_input())
H={0:"Twelve",1:"one",2:"two",3:"three",4:"four",5:"five",6:"six",7:"seven",8:"eight",9:"nine",10:"ten",11:"eleven",12:"twelve"}
M={1:"one minute",2:"two minutes",3:"three minutes",4:"four minutes",5:"five minutes",6:"six minutes",7:"seven minutes",8:"eight minutes",9:"nine minutes",10:"ten minutes",11:"eleven minutes",12:"twelve minutes",13:"thirteen minutes",14:"fourteen minutes",15:"quarter",
   16:"sixteen minutes",17:"seventeen minutes",18:"eighteen minutes",19:"nineteen minutes",20:"Twenty minutes",
   21:"twenty one minutes",22:"twenty two minutes",23:"twenty three minutes",24:"twenty four minutes",
   25:"twenty five minutes",26:"twenty six minutes",27:"twenty seven minutes",28:"twenty eight minutes",29:"twenty nine minutes",30:"half",45:"quarter"}
if m==0:
    ans=H[h]+" o' clock"
elif 30>=m>0:
    ans=M[m]+" past "+H[h]
elif 59>m>30:
    if m==45:
        ans=M[m]+" to "+H[h+1]
    else:
        ans=M[60-m]+" to "+H[h+1]
print ans