0
Is there an easy way to write nest statements in if statement
if it please tell me
1 ответ
0
Some languages allow you to use switch so you'd write:
switch(i) {
case 1:
....
break;
case 2:
....
break;
....
}
instead of nested if statements:
if (i == 1) {
....
} else if (i == 2) {
...
} else if ....