ammulu Posted December 16, 2011 Report Posted December 16, 2011 Given the the C++ classes, which of the following statements is/are true about accelerate(...) and consumeFuel(...) methods of Vehicle? (Select all that apply) class Vehicle { protected: void start(); void stop(); virtual void accelerate(int speed); virtual void consumeFuel(int mpg); public: .... }; class Car: public Vehicle { protected: .... public: .... }; Choose at least one answer. A. Are inherited by the derived class (Car). B. Can not be inherited by the derived class (Car). C. Are always required to (MUST) be overriden by the derived class (Car). D. Support dynamic (late) binding. E. May be overloaded by the derived class (Car) if need be. Koncham ee answer ento cheppandi...Thank you
sujithrede Posted December 16, 2011 Report Posted December 16, 2011 [quote name='ammulu' timestamp='1324071150' post='1301157004'] Given the the C++ classes, which of the following statements is/are true about accelerate(...) and consumeFuel(...) methods of Vehicle? (Select all that apply) class Vehicle { protected: void start(); void stop(); virtual void accelerate(int speed); virtual void consumeFuel(int mpg); public: .... }; class Car: public Vehicle { protected: .... public: .... }; Choose at least one answer. A. Are inherited by the derived class (Car). B. Can not be inherited by the derived class (Car). C. Are always required to (MUST) be overriden by the derived class (Car). D. Support dynamic (late) binding. E. May be overloaded by the derived class (Car) if need be. Koncham ee answer ento cheppandi...Thank you [/quote] none of the above leda [url=http://www.desigifs.com/gifs/1226/brahmanandam][img]http://www.desigifs.com/sites/default/files/brahmam_buildup5_0.gif[/img][/url]
ammulu Posted December 16, 2011 Author Report Posted December 16, 2011 [quote name='sujithrede' timestamp='1324071323' post='1301157026'] none of the above leda [url="http://www.desigifs.com/gifs/1226/brahmanandam"][img]http://www.desigifs.com/sites/default/files/brahmam_buildup5_0.gif[/img][/url] [/quote] unte cheppedhanni kadha
k2s Posted December 16, 2011 Report Posted December 16, 2011 see this similar example: [url="http://www.tenouk.com/download/Module14.txt"]http://www.tenouk.co...ad/Module14.txt[/url] [url="http://www.codersource.net/c/c-tutorials/c-tutorial-on-inheritance.aspx"]http://www.codersource.net/c/c-tutorials/c-tutorial-on-inheritance.aspx[/url]
ammulu Posted December 16, 2011 Author Report Posted December 16, 2011 [quote name='k2s' timestamp='1324071375' post='1301157036'] see this similar example: [url="http://www.tenouk.com/download/Module14.txt"]http://www.tenouk.co...ad/Module14.txt[/url] [/quote] oka option cheppava
k2s Posted December 16, 2011 Report Posted December 16, 2011 [quote name='ammulu' timestamp='1324071401' post='1301157038'] oka option cheppava [/quote]
sujithrede Posted December 16, 2011 Report Posted December 16, 2011 [quote name='ammulu' timestamp='1324071356' post='1301157031'] unte cheppedhanni kadha [/quote] [url=http://www.desigifs.com/gifs/102/pawan-kalyan][img]http://www.desigifs.com/sites/default/files/Pawan Gifss (26).gif[/img][/url]
ammulu Posted December 16, 2011 Author Report Posted December 16, 2011 [quote name='k2s' timestamp='1324071456' post='1301157044'] [/quote] ala kadhu kani...answer chepppava..please vallaki exam time ayipothundhi
Jambhalheart Posted December 16, 2011 Report Posted December 16, 2011 C++ marchipoya. kaani, according to OOPS concept, option A is correct as child class is deriving from base class so the base class methods will be available as they r under protected in base class. option E is also possible
k2s Posted December 16, 2011 Report Posted December 16, 2011 [quote name='ammulu' timestamp='1324071520' post='1301157057'] ala kadhu kani...answer chepppava..please vallaki exam time ayipothundhi [/quote] ee link lo unnadi sadavali..... [url="http://www.codersource.net/c/c-tutorials/c-tutorial-on-inheritance.aspx"]http://www.codersource.net/c/c-tutorials/c-tutorial-on-inheritance.aspx[/url]
galigannarao Posted December 16, 2011 Report Posted December 16, 2011 [quote name='Maddy_Rulez' timestamp='1324071682' post='1301157077'] C++ marchipoya. kaani, according to OOPS concept, option A is correct as child class is deriving from base class so the base class methods will be available as they r under protected in base class. [/quote] virtual ani define cheste they may be overridden in the derived class
Spartan Posted December 16, 2011 Report Posted December 16, 2011 A E..... C. Are always required to (MUST) be overriden by the derived class (Car)...e option lo....always lekapote...C kuda add seskovachu...
Recommended Posts