1. Engineering
  2. Computer Science
  3. select the best answer the objective is to prove that...

Question: select the best answer the objective is to prove that...

Question details

Select the best answer. The objective is to prove that when this program ends, s n(n+1)/2. Check the best loop invariant before each iteration to use in order to achieve my objective. for (i-1; i <= n; i++) None of these answers O s -i(i+1)/2 for all i >-1 O s (i-1)i/2 for all i >-1
Solution by an expert tutor
Blurred Solution
This question has been solved
Subscribe to see this solution