Closed matthiasrebbe closed 3 years ago
Yes - that's there by design. Note that the "default" option doesn't necessarily have to be the last in the list, so the break command is there to ensure that the code won't fall through to any following options unless the break is explicitly removed.
When the switch control structure is completed on return then not only after case the break keyword is placed, but also after default.
this is how it looks after completion.