Asked by Sara
3. After following statements have executed, find the value of the variable a.
int a=5;
while (a<20)
a=a+3;
4. After following statements have executed, find the value of the variable a.
int a=0;
while (a<12)
a++;
5. After following statements have executed, find the value of the variable a.
int a=15;
while (a>0)
a=a-3;
6. After following statements have executed, find the value of the variable a.
int a=2, i=0;
while (i<=5){
a=a+i;
i++;
}
7. After following statements have executed, what will be appear on the output window
int i=0, a=0;
while(i<10){
a=a+i*i;
i=i+2;
cout<<a<<endl;
}
8. After following statements have executed, what will be appear on the output window
int i=10, a=0;
while(i>3){
a=a+i*i;
i=i-2;
cout<<a<<endl;
}
Just write the answers.
int a=5;
while (a<20)
a=a+3;
4. After following statements have executed, find the value of the variable a.
int a=0;
while (a<12)
a++;
5. After following statements have executed, find the value of the variable a.
int a=15;
while (a>0)
a=a-3;
6. After following statements have executed, find the value of the variable a.
int a=2, i=0;
while (i<=5){
a=a+i;
i++;
}
7. After following statements have executed, what will be appear on the output window
int i=0, a=0;
while(i<10){
a=a+i*i;
i=i+2;
cout<<a<<endl;
}
8. After following statements have executed, what will be appear on the output window
int i=10, a=0;
while(i>3){
a=a+i*i;
i=i-2;
cout<<a<<endl;
}
Just write the answers.
Answers
Answered by
Steve
better yet, why don't you just execute the code?
There are no AI answers yet. The ability to request AI answers is coming soon!
Submit Your Answer
We prioritize human answers over AI answers.
If you are human, and you can answer this question, please submit your answer.