Time limit
2s
Memory limit
128 MB
Today is Monday, January 1, 2007. Given a date in 2007, write a program that determines the day of the week for that date.
The first line contains a month x and a day y, separated by a space. 1 <= x <= 12 and 1 <= y <= 31.
The number of days in each month of 2007 is as follows.
The input date is guaranteed to be a valid date in 2007.
Print the day of the week for the given date as one of SUN, MON, TUE, WED, THU, FRI, or SAT.