George doesn't have a good memory, so he can't remember how many days of the year it…
- User
George doesn't have a good memory, so he can't remember how many days of the year it was. He only knows what date it is today and how many Saturdays it is.
Write a program for George that by taking today's date and day of the week and taking another desired day, he can tell how many Saturdays that desired day is in this year.
input Entry included T T is a different scenario.
In the first line of each scenario comes the day and month, and then the day of the week.
In the second line of each scenario comes the day George wants to know what Saturday it is.
1 ≤ T ≤ 1000 1≤T≤1000
The names of the months of the year are given in the entry as Farvardin, Ordibehesht, Khordad, Tir, Mordad, Shahrivar, Mehr, Aban, Azar, Dey, Bahman and Esfand.
Also, the first 6 months of the year have 31 days, the next 5 months have 30 days, and the last month has 29 days. (We don't have a leap year.)
The names of the days of the week are also input as shanbe, 1shanbe, 2shanbe, 3shanbe, 4shanbe, 5shanbe, and jome, and should be output as such.
output For each scenario, you should print a line indicating what day of the week it is.
Note that the judging system is case sensitive.
Example Sample entry 1 5 11 Khordad jome 18 Azar 18 Khordad 5shanbe 16 Shahrivar 25 Khordad 3shanbe 12 Esfand 15 Ordibehesht 1shanbe 1 Azar 23 Tir 3shanbe 22 Ordibehesht Plain text Sample output 1 1 shanbe 5 shanbe 5 shanbe jome 3 Shanbe Plain text Sample input 2 10 2 Bahman 4shanbe 19 Khordad 29 Azar 5shanbe 13 Dey 29 Shahrivar jome 10 Tir 7 Mordad shanbe 16 Mordad 29 Aban 4shanbe 24 Shahrivar 31 Khordad shanbe 21 Ordibehesht 25 Farvardin 5shanbe 25 Ordibehesht 24 Dey 1shanbe 5 Mehr 26 Tir shanbe 12 Azar 15 Esfand 2shanbe 25 Shahrivar Plain text Sample output 2 1 shanbe 5 shanbe 2 Shanbe 2 Shanbe 1 shanbe 1 shanbe 1 shanbe 4 Shanbe jome jome c++
- Assistant