/*Question: what is the output after executed the following Program*/ #include using namespace std3; int main() { int X, Y; int Array[8] ={2,4,6,8,10,12,14,16}; X=03; while(X<3) { Array[X]=Array[X]+1; X+=3; } Y = 5; while( Y > 2) { int X = Y%2; %3D Array[X]=Array[X]-1;Y--;} cout<< X<<","<< Array[X]; return 0; }//end main

C++ Programming: From Problem Analysis to Program Design
8th Edition
ISBN:9781337102087
Author:D. S. Malik
Publisher:D. S. Malik
Chapter8: Arrays And Strings
Section: Chapter Questions
Problem 1TF: Mark the following statements as true or false. A double type is an example of a simple data type....
icon
Related questions
Question
I need the answer as soon as possible
/*Question: what is the output
after executed the following
Program*/
#include<iostream>
using namespace std;
int main()
{
int X, Y;
int Array[8] ={2,4,6,8,10,12,14,16};
X-0;
while(X<3) {
Array[X]=Array[X]+1;
X+=3; }
Y = 5;
while( Y > 2) {
int X
Y%2;
%3D
Array[X]=Array[X]-1;Y--;}
cout<< X<<","<< Array[X];
return 0;
}//end main
Transcribed Image Text:/*Question: what is the output after executed the following Program*/ #include<iostream> using namespace std; int main() { int X, Y; int Array[8] ={2,4,6,8,10,12,14,16}; X-0; while(X<3) { Array[X]=Array[X]+1; X+=3; } Y = 5; while( Y > 2) { int X Y%2; %3D Array[X]=Array[X]-1;Y--;} cout<< X<<","<< Array[X]; return 0; }//end main
Expert Solution
steps

Step by step

Solved in 4 steps with 2 images

Blurred answer
Knowledge Booster
Encryption and Decryption
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning