โ Back to If Statements
Question 269
Day of the Week Name
Day of the Week Name
Read a day number from1to7withscanfand print its name with no trailing newline, where1isMondayand7isSunday:1->Monday,2->Tuesday,3->Wednesday,4->Thursday,5->Friday,6->Saturday,7->Sunday. For input1the output isMonday; for6it isSaturday; for7it isSunday.
Expected Output:
Monday
Topics:
If Statements
Code Editor
1
Tab to indent ยท Ctrl+Enter to run ยท Ctrl+Space to expand shortcuts (p, fori)
Your Output
Run your code to see the output here...
Test Cases
Run your code to see test case results.