Question: You are given two values, c and n. c is the current day of the week - 0 is Sunday, 1 is Monday, 2 is

You are given two values, c and n. c is the current day of the week - 0 is Sunday, 1 is Monday, 2 is Tuesday, etc. n is the number of days that have elapsed since day c. Print out what day that will be.

Input Format

both c and n will be integers

Constraints

0 <= c <= 6 -2 billion <= n <= 2 billion

Output Format

Output the full name of the day of the week.

Sample Input 0

3 2 

Sample Output 0

Friday 

Explanation 0

Day 3 is Wednesday. 2 days after Wednesday is Friday

Sample Input 1

4 -1 

Sample Output 1

Wednesday 

Explanation 1

Day 4 is Thursday. 1 day before Thursday (previous day) is Wednesday. A negative value for n indicates we are looking for previous days.

Screenshot of the output

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!