Hector9810 Hector9810
  • 04-10-2019
  • Computers and Technology
contestada

)Dynamically allocate an object of Banana, using the pointer variable daco.

a)Banana * = new daco;

b)daco = new * Banana;

c)daco = new & Banana;

d)daco = new Banana;

Respuesta :

ExieFansler ExieFansler
  • 04-10-2019

Answer:

d) daco = new Banana;

Explanation:

Dynamically allocated variables have their memory allocated in the heap memory.We declare a dynamical variable like this:-

int *a=new int ;

It means a pointer a is created on the stack memory which hold the address of the block that hold the value of variable a in heap memory.

We already have the pointer daco. We just have to initialize with keyword new.

It will be like daco=new Banana; which matches the option d.

Answer Link
taylorlattimore21
taylorlattimore21 taylorlattimore21
  • 05-11-2020

Answer:

What can I help you with:)

Explanation:

Answer Link

Otras preguntas

Find the value of x xx in the isosceles triangle shown below.
The essential difference between an experiment and an observational study is
List at least two natural causes of global climate change?
BRAINLIEST AND FIVE STARS TO CORRECT ANSWER
The radius of a sphere is 3 in. What is the sphere's volume? Round to the nearest tenth, if necessary.
What is the area of regular pentagon with a side of 12 inches? Round the answer to the nearest 10th.
65000 people watched a footbal match between leeds and chelsea. 42000 were chelesa fans. what fraction were chelsea fans?
What are 12 all the prepositions??
What is the maximum vertical distance between the line y = x + 20 and the parabola y = x2 for −4 ≤ x ≤ 5?
What is the main reason voters choose political candidates