Switch is a statement in javascript that's used to control the data flow in programs. With other words to be able to decide what should happen from different cases or actions. Basically the same way one does with if and else, which most people probably are familiar with by now. They work in similar ways..