Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Question 31 What are the three values Blank 1, Blank 2, and Blank 3 in order that will be displayed when the following code is

Question 31

What are the three values Blank 1, Blank 2, and Blank 3 in order that will be displayed when the following code is executed?

 class Value { public: int i = 15; }; class Test { public: void first() { int i = 5; Value *v = new Value(); v->i = 25; second(*v, i); cout << " " << v->i << endl; } void second(Value v, int i) { i = 0; v.i = 20; Value val; v = val; cout << v.i << " " << i; } }; int main() { Test *t = new Test(); t->first(); } 

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

More Books

Students also viewed these Databases questions

Question

5. Arranging for the training facility and room.

Answered: 1 week ago

Question

1. Discuss the five types of learner outcomes.

Answered: 1 week ago