【单选题】【消耗次数:1】
下列关于纯虚函数与抽象类的描述中,()是错误的。
抽象类是指具有纯虚函数的类
纯虚函数是一个特殊的虚函数,它没有具体的实现
一个基类中说明具有纯虚函数,该基类的派生类一定不再是抽象类
抽象类只能作为基类来用,其纯虚函数的实现由派生类给出
参考答案:
复制
纠错
相关题目
【单选题】 含有一个或多个纯虚函数的类称为()。
①  抽象类
②  具体类
③  虚基类
④  派生类
【单选题】 以下基类中的成员函数表示纯虚函数的是()
①  virtual void tt()=0
②  void tt(int)=0’
③  virtual void tt(int)
④  virtual void tt(int){}
【单选题】 以下基类中的成员函数表示纯虚函数的是()
①  virtual void tt()=0
②  void tt(int)=0
③  virtual void tt(int)
④  virtual void tt(int){}
【单选题】 以下基类中的成员函数表示纯虚函数的是()
①  virtual void tt()=0
②  void tt(int)=0’
③  virtual void tt(int)
④  virtual void tt(int){}
【单选题】 以下基类中的成员函数表示纯虚函数的是()
①  virtual void tt()=0
②  void tt(int)=0
③  virtual void tt(int)
④  virtual void tt(int){}
【单选题】 类B是类A的公有派生类,类A和类B中都定义了虚函数func(),p是一个指向类A对象的指针,则p-A::func()将()
①  调用类A中的函数func()
②  调用类B中的函数func()
③  根据p所指的对象类型而确定调用类A中或类B中的函数func()
④  既调用类A中函数,也调用类B中的函数
【单选题】 类B是类A的公有派生类,类A和类B中都定义了虚函数func(),p是一个指向类A对象的指针,则p->A::func()将()
①  调用类A中的函数func()
②  调用类B中的函数func()
③  根据p所指的对象类型而确定调用类A中或类B中的函数func()
④  既调用类A中函数,也调用类B中的函数
【判断题】 拥有abstract方法的类是抽象类,但抽象类中可以没有abstract方法。
①  正确
②  错误
【判断题】 实现接口的类不能是抽象类。
①  正确
②  错误
【单选题】 下列描述中,()是抽象类的特征。
①  可以说明虚函数
②  可以定义友元函数
③  可以进行构造函数重载
④  不能说明其对象
随机题目
【单选题】 It is the general manager who makes the _______decisions in business.
①  beginning
②  finishing
③  first
④  final
【单选题】 Those gifts o rare books that were given t us were deeply _____.
①  appreciated
②  approved
③  appealed
④  applied
【单选题】 Haven’t seen you for ages! What are you busy doing now?____________
①  I hate the weather here.
②  My hair is getting a bit longer.
③  I am working part time in a bookshop, you know.
④  Yeah, thanks for coming.
【单选题】 We are planning an outing. _________ Sure.
①  Where are you going?
②  When will you leave?
③  How is everything?
④  Do you want to join us?
【单选题】 It is dangerous to ______ outdated(过时的) ideas and theories.
①  cling to
②  strive for
③  run through
④  resort to
【单选题】 I had my meals ______ when I was ill in bed with a bad cold.
①  to bring
②  bring
③  brought
④  bringing
【单选题】 Don’t make faces in class.____________
①  Excuse me, I am wrong.
②  Certainly, I will.
③  That’s OK.
④  Sorry, I won’t do it again.
【单选题】 He offered to ___ her a hand as the suitcase was too heavy for her to carry.
①  lend
②  help
③  grant
④  loan
【单选题】 Our new house is very ____ for me as I can get to the office in five minutes.
①  adaptable
②  convenient
③  available
④  comfortable
【单选题】 Have you any oranges and apples?____________
①  The oranges are very cheap.
②  You like apples, dont you?
③  Of course, we have some fruits.
④  Yes, madam, on the second shelf over there.