Hotfix code formatting (#19387)
This commit is contained in:
committed by
Jonathan Grah
parent
7fc676a4d3
commit
e6c9c6c124
@ -47,7 +47,7 @@ else
|
|||||||
int a = 300;
|
int a = 300;
|
||||||
if(a < 200)
|
if(a < 200)
|
||||||
{
|
{
|
||||||
printf("a is less than 200\n" );
|
printf("a is less than 200\n");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -88,7 +88,7 @@ else
|
|||||||
int a = 300;
|
int a = 300;
|
||||||
if(a == 100)
|
if(a == 100)
|
||||||
{
|
{
|
||||||
printf("a is equal to 100\n" );
|
printf("a is equal to 100\n");
|
||||||
}
|
}
|
||||||
else if(a == 200)
|
else if(a == 200)
|
||||||
{
|
{
|
||||||
@ -147,7 +147,7 @@ The switch statement is often faster than nested if...else (not always). Also, t
|
|||||||
### Syntax of switch case
|
### Syntax of switch case
|
||||||
```
|
```
|
||||||
switch (n)
|
switch (n)
|
||||||
{
|
{
|
||||||
case constant1:
|
case constant1:
|
||||||
// code to be executed if n is equal to constant1;
|
// code to be executed if n is equal to constant1;
|
||||||
break;
|
break;
|
||||||
|
Reference in New Issue
Block a user