This forum is now read-only. Please use our new forums at discuss.codecademy.com.

Control Flow: Switch Forum

View Course » View Exercise

258 points
550c4ba19113cbab3c00040d_941139326
Submitted by
Darkshad3
over 2 years ago

i don't understand this at all

i don't know what a switch is i don't know what a break is & what is default & why & when would they / are they used

it never explained it to begin with & it expects me to use it.


1 vote

permalink

switch is multiple "if"s in one.
break ends case, so it don't try to do code in rest of cases
and defauld is what is done if all cases can't do their part of code

230 points
E914c626e28715075238f6e14df5b019?s=140&d=retro
Submitted by
Kamil118
over 2 years ago