Question: QUESTION 1 1 What is the difference in execution between the following two code segments? Example 1 : intCounter = 0 Do While intCounter 1

QUESTION 11
What is the difference in execution between the following two code segments?
Example 1:
intCounter =0
Do While intCounter 10
IstOutput.Items.Add(intCounter * intCounter)
intCounter = intCounter +1
Loop
Example 2:
For intCounter 10
IstOutput.Items.Add(intCounter * intCounter)
Next intCounter
The loop in Example 1 will execute one more time than Example 2.
Example 1 is an infinite loop while Example 2 is not.
Both loops will execute in the same manner.
The loop in Example 1 will never be executed.
QUESTION 1 1 What is the difference in execution

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!