Switch Statement – JavaScript Basics

It is used to perform different actions on different conditions. How does it works?? – switch expression is classified once & value of expression is compared with values of each case. The associated block of code is executed if there’s a match. <!DOCTYPE html> <html> <body> <p id=”ex”></p> <script> var day; switch (new Date().getDay()) { case

Continue reading Switch Statement – JavaScript Basics