Tagged: switch in c language

switch statement in C 40

switch statement in C

The switch statement in C is very powerful decision making statement. It reduces the complexity of the program. Hence increases the readability of the program. Switch statement accepts single input from the user and based on that input executes a particular block of statements. Syntax of switch statement in C: switch(expression){ case constant 1: perform this; case constant 2: perform this; case constant 3: perform this; case constant 4: perform this; . . . default: perform this; } Control passes to the statement whose case constant-expression matches the value of switch ( expression ). The switch statement can include any...

FREE C Cheatsheet - Speed Up Your C Programming.

FREE C Cheatsheet - Speed Up Your C Programming.

Download a 7-page free cheat sheet for easy and quick access to C Concepts, Snippets, and Syntax.

Thank you! Check you inbox and access your cheat-sheet