a C program to a determine the day of the week based on the input number using switch-case.

Explanation
1. Define the input variable:
In the C program, you would start by declaring a variable to store the input number representing the day of the week. For example:
int dayNumber;
2. Use a switch-case statement:
Next, you would use a switch-case statement to determine the day of the week based on the input number. The switch-case statement allows you to compare the input value against different cases and execute the corresponding code block.
Here's an example of how you can implement this in C:
switch (dayNumber) {
case 1:
printf("Sunday\n");
break;
case 2:
printf("Monday\n");
break;
case 3:
printf("Tuesday\n");
.
.
.
break;
default:
printf("Invalid input\n");
}
3. Display the output:
After the switch-case statement, you would prompt the user to enter the day number and then display the corresponding day of the week based on the input.


Previous :-->> 7. write a C program to calculate the electricity bill based on units consumed using switch case.
 -->> NEXT: 9. Develop a program in C to calculate the area of a triangle or rectangle based on user input using 'switch-case'.
-->>ALL Conditionl statements Programs