Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

U x Take Test: Quiz 6 2016 Fax (G which 28% Thu 3:37 PM Sakib Khan Q. Secure htt

ID: 3789928 • Letter: U

Question


U x Take Test: Quiz 6 2016 Fax (G which 28% Thu 3:37 PM Sakib Khan Q. Secure https://bbhosted statement is incorre x C chegg study l Guided solu x C Please Let Me Know which x sakib ccess D Guest uny.edu/webar assessment/take/launch isp? course assessment ide 1004835.1 access Apps Minbox (1,405) saki... LaGuardia Commu D Apple 1322702 18co... o v Question Completion D Disney D ESPN D Yahoo! Imported From Safari Status: QUESTION 1 Which statement is incorrect? 10 points Save Answer O virtual functions allow old code cal new code yet defined code) to (not O In a class, functions declared with the virtual keyword need not be defined O the virtual function mechanism binds the right function to objects O virtual functions are implemented with a table lookup that is done at run time QUESTION 2 Which statement is incorrect? 10 points Save Answer O A pointer to objects of derived class can be assigned pointers to objects of the base class in the inheritance hierarchy a It is useful to define a class for which no objects may be defined O Aclass that has a pure virtual member function is called an abstract base class O You can assign (oopy objects of derived type to objects of base type QUESTION 3 10 points Save Answer Which statement is incorrect? The base class destructor must be virtual It is legal to have al member functions of a class to be pure virtual functions o Only member functions can be virtual, constructors cannot be virtual The binding of virtual functions is done atruntime, when called using an object

Explanation / Answer

1.

Statement 2 is incorrect, because function needs to be define be it virtual function or other. In virtual function only late binding is done which means dynamic binding (at run time).

2.

Statement 4 is incorrect, Since it is not possible to assign object of derived type to base type, although you you can assign object of base type to derived type.

3.

Statement 3 is incorrect, constructor can also be virtual

4.

Statement 1. Polymorphism. Static binding, virtual function and late binding is all part of virtual function and related to memory binding.