Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A) // memory address of p is 1000 // memory address of a is 1004 // memory address of b is 1008 Int *p; Int

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

SQL For Data Science Data Cleaning Wrangling And Analytics With Relational Databases

Authors: Antonio Badia

1st Edition

3030575918, 978-3030575915

More Books

Students also viewed these Databases questions