write a short note on switch case statement in javascript code example
Example: js switch case
switch(expression) {
case x:
// code block
break;
case y:
// code block
break;
default:
// code block
}
switch(expression) {
case x:
// code block
break;
case y:
// code block
break;
default:
// code block
}