Ask Question
25 February, 22:33

Create a Word document or text file named Part3 that contains answers to the following:

1. Consider the declaration in SumAllArr. java: int[] arr1 = new int[max + 1];

a. How many array elements does this statement create?

b. Why do we have max + 1?

c. Can we just use max and have the program still work correctly?

2. Before the while-loop in SumAllArr. java we have i = 1.

a. Why is it there?

b. Can we use another variable instead?

3. The do-while loop in SumAllArr. java is implemented using (++i < = max).

a. Provide an alternative expression that implements the same logic.

b. What will (i+ + < = max) result in?

+5
Answers (1)
  1. 25 February, 23:49
    0
    11111
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “Create a Word document or text file named Part3 that contains answers to the following: 1. Consider the declaration in SumAllArr. java: ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers