atcoder#ABC267A. [ABC267A] Saturday

[ABC267A] Saturday

Score : 100100 points

Problem Statement

One day, tired from going to school, Takahashi wanted to know how many days there were until Saturday. We know that the day was a weekday, and the name of the day of the week was SS in English. How many days were there until the first Saturday after that day (including Saturday but not the starting day)?

Constraints

  • SS is Monday, Tuesday, Wednesday, Thursday, or Friday.

Input

Input is given from Standard Input in the following format:

SS

Output

Print the answer as an integer.

Wednesday
3

It was Wednesday, so there were 33 days until the first Saturday after that day.

Monday
5