switch (a) { case 0: foo; case 1: bar; break; ... } // you mostly want either: switch (a) { case 0: case 1: foo; break; } // or switch (a) { case 0: foo; break; case 1: bar; break; }