Quiz on Expressions

Test your understanding of expressions.

We'll cover the following...

Expressions in functional programming and OCaml

1.

(Select all that apply) Which of the following typical language elements of imperative programming languages do not exist in functional programming languages?

A.

Functions such as

square x = x * x
B.

Variable assignments such as

c = c + 1
C.

for/while loops such as

for (int i = 0; i < n; i++) {
   c = c + 1
}

while (i < n) {
   c = c + 1
}

1 / 8