Question: rewrite the following while loop as an equivalent for loop: int i = 1; int total = 0; while( i < 100 ) { total
rewrite the following while loop as an equivalent for loop: int i = 1; int total = 0; while( i < 100 ) { total += i; i++; }
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
