subject

What is the output of the following code?

int x;
int *p;
int *q;

p=new int [10];

q=p;
*p=4;

for (int j = 0; j < 10; j++)
{
x = *p;
p++;
*p = x + j;
}

for (int k = 0; k < 10; k++)
{
cout < < *q < < "";
q++;
}

cout < < endl;

ansver
Answers: 1

Other questions on the subject: Computers and Technology

image
Computers and Technology, 21.06.2019 22:50, prettybaby406
Explain why it is reasonable to assume that receiving 3 duplicate acks in tcp is an indication that the network is not currently congested.
Answers: 1
image
Computers and Technology, 22.06.2019 22:30, juliangarcia0002
Which of the following factors would your hypothetical supervisor look at when deciding whether to test a biological material sample for dna? the amount of other evidence you have implicating a suspect in a crime the annual budget for the crime lab both of the above none of the above; you would almost always order a test
Answers: 3
image
Computers and Technology, 23.06.2019 06:40, euniceyi56
How many nibbles can be stored in a 16-bit word?
Answers: 1
image
Computers and Technology, 23.06.2019 14:00, shawn423
How are stop motion special effects in animated films created
Answers: 1
You know the right answer?
What is the output of the following code?

int x;
int *p;
int *q;

Questions in other subjects:

Konu
Mathematics, 09.03.2021 19:00