读书人

C++有关问题求大神答案(最好英语好的

发布时间: 2012-03-30 17:32:09 作者: rapoo

C++问题,求大神答案(最好英语好的)
这道题目我不太懂是什么意思,有高手能帮帮忙吗??(这道题具体要有那些功能、要求)
- inheritance syntax
- overriding methods

Task:
Implement a Solarcar class which inherits from Vehicle. A Solarcar has an extra attribute batterylevel (float between 0.0 and 1.0). Provide the necessary methods.
The method info() is overridden in Solarcar because the info on the batterylevel is also shown directly after the speed information. Try to reuse Vehicle::info() in Solarcar::info().
Make it possible to call the same constructor with zero, one, two or three parameters.
Create a suitable test application.


[解决办法]
顶楼上,楼主还是自己动手写写,很简单的...多coding,这样学习的快...

读书人网 >C++

热点推荐