Question: Take each of the loops programed here and give equivalent looping structures that do the same. Note that the first 1 is the only one
Take each of the loops programed here and give equivalent looping structures that do the same. Note that the first 1 is the only one that requires you do both equivalent loops using C++(through visual studio ).
1. //Program 2 additional loops that are equivalent to the following:
for (int i = 6; i < 10; i++)
cout << i << " ";
cout << endl;
2. //Program 1 additional loop equivalent the this the following
int w = 35;
while (--w>0)
{
if (w > 5)
w -= 4;
cout << "T-" << w << ", ";
}
cout << "Lift-off" << endl;
3. //program 1 loop equivalent to the following:
int loop = 10;
do{
cout << --loop << " ";
} while (loop > 5);
cout << endl;
You can even get more creative:
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
