Menu
×
×
Correct!

Exercise:

Complete the switch statement, and add the correct keyword at the end to specify some code to run if there is no case match in the switch statement.

int day = 3; switch (day) { case 1: Console.WriteLine("Today is Saturday"); break; case 2: Console.WriteLine("Today is Sunday"); break; default: Console.WriteLine("Looking forward to the Weekend"); break; }

Not Correct

Click here to try again.

Correct!

Next ❯
int day = 3;
switch () 
{
   1:
    Console.WriteLine("Today is Saturday");
    break;
   2:
    Console.WriteLine("Today is Sunday");
    ;
  :
    Console.WriteLine("Looking forward to the Weekend");
    ;
}

  
  
  




Log in to keep your progress
Sign up to keep your progress

Completed 0 of 58 Exercises:

C# Syntax
C# Comments
C# Variables
C# Data Types
C# User Input
C# Operators
C# Math
C# Strings
C# Booleans
C# If...Else
C# Switch
C# Loops
C# Arrays
C# Methods
C# Classes/Objects
C# Exceptions

×

Reset the Score?

This will reset the score of ALL 58 exercises.

Are you sure you want to continue?



×

Congratulations!

You have finished all 58 C# exercises.

Share your score: