mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2024-12-23 17:41:41 +00:00
removed break statements from if-then-else
This commit is contained in:
parent
a6359357fd
commit
82a37a456a
@ -119,11 +119,11 @@ foreach (int foreach_demo_var in foreach_demo) {
|
|||||||
} // foreach works on any iterable collection
|
} // foreach works on any iterable collection
|
||||||
|
|
||||||
if (a == 0) {
|
if (a == 0) {
|
||||||
break;
|
stdout.printf("%d\n", a);
|
||||||
} else if (a > 1) {
|
} else if (a > 1) {
|
||||||
stdout.printf("%d\n", a);
|
stdout.printf("%d\n", a);
|
||||||
} else {
|
} else {
|
||||||
break;
|
stdout.printf("A is less than 0");
|
||||||
} // if-then-else
|
} // if-then-else
|
||||||
|
|
||||||
switch (a) {
|
switch (a) {
|
||||||
|
Loading…
Reference in New Issue
Block a user