course-c

if-else

if-else ambiguities

:::: {.columns}

::: {.column}

:::

::: {.column}

:::

::::

else-if

switch

:::: {.columns}

::: {.column width=”40%”}

  switch (expression) {
    case const-expr:
      statements
    case const-expr:
      statements
    default:
      statements
  }

:::

::: {.column width=”60%”}

:::

::::

while

for

do-while

break

continue

goto

Exercise