Using:
switch (expression) { case 0: [self taskA]; break; case 1: case 2: [self taskB]; break; default: break; }
Change 1:
In switch we pronounce the term fall-through . Whenever control reaches a label, case 0: it drops to break . In break control is sent to switch closing braces.
If break does not occur, it moves on to the next case , as in case , then case 2 . So above case 1 and case 2 contains one break statement.
source share