3 ms·
The switch statement offers the ability to provide a default opperation, such as tell the user the command was not found. You could add an undefined property c
by robmcm 13y ago
The switch statement offers the ability to provide a default opperation, such as tell the user the command was not found.
You could add an undefined property check on the dispatch table, but then you have as much and more complex code IMO.