Mask-group

The Switch Statement



  • The general form is - 

switch (condition){

case value 1: 

//do this;

break;

case value 2:

//do this;

break;

………..

default:

//do this if all above cases do not match;

}

  • Example: