Microsoft
98-361 · Question #340
You are writing a C# program that needs to iterate a fixed number of times. You need to make sure that your code is easy to understand and maintain even when the loop body contains complex code…
The correct answer is B. for. See the full explanation below for the reasoning.
Question
You are writing a C# program that needs to iterate a fixed number of times. You need to make sure that your code is easy to understand and maintain even when the loop body contains complex code. Which of the following C# statements provide the best solution for this requirement?
Options
- Awhile
- Bfor
- Cfor each
- Ddo-while
How the community answered
(30 responses)- A3% (1)
- B77% (23)
- C7% (2)
- D13% (4)
Community Discussion
No community discussion yet for this question.