+2 votes
in Mathematics by kratos

In the for statement: for (exp1; exp2; exp3) { … } where exp1, exp2 and exp3 are expressions. What is optional?

(A) of the expressions is optional.

(B) Only exp1 is optional.

(C) Only exp1 and exp3 are optional.

(D) All the expressions are optional.

1 Answer

+5 votes
by kratos
 
Best answer

Correct option - (D) All the expressions are optional.

Explanation:-

All the expressions are optional. For (;;) is a valid statement in C.

...