Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

write the exact output of the following code box: A) // memory address of p is 1000 // memory address of a is 1004 //

write the exact output of the following code box:

A)

// memory address of p is 1000

// memory address of a is 1004

// memory address of b is 1008

Int *p;

Int a =15;

Int b =20;

P=a;

*p=b;

Cout << a << endl;

B)

// memory address of p is 1000

// memory address of a is 1004

// memory address of b is 1008

Int *p;

Int a =15;

Int b =20;

P=a;

*p=b;

Cout << *p << endl;

C)

// memory address of p is 1000

// memory address of a is 1004

// memory address of b is 1008

Int *p;

Int a =15;

Int b =20;

P=a;

*p=b;

Cout << p << endl;

D)

// memory address of p is 1000

// memory address of a is 1004

// memory address of b is 1008

Int *p;

Int a =15;

Int b =20;

P=a;

*p=b;

Cout << &p << endl;

E)

// memory address of p is 1000

// memory address of dynamic int array is 2000

Int *p;

P=new int[5];

For (int i = 0; i<5; ++i)

P[i]= 5 - i;

Cout << &(p[2])<< endl;

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Microsoft Visual Basic 2008 Comprehensive Concepts And Techniques

Authors: Gary B. Shelly, Corinne Hoisington

1st Edition

1423927168, 978-1423927167

More Books

Students also viewed these Databases questions

Question

Create a summary of experience

Answered: 1 week ago

Question

3 How supply and demand together determine market equilibrium.

Answered: 1 week ago

Question

1 What demand is and what affects it.

Answered: 1 week ago