【单选题】【消耗次数:1】
若classB中定义了一个classA的类成员Aa,则关于类成员的正确描述是()
在类B的成员函数中可以访问A类的私有数据成员
在类B的成员函数中可以访问A类的保护数据成员
类B的构造函数可以调用类A的构造函数做数据成员初始化
类A的构造函数可以调用类B的构造函数做数据成员初始化
参考答案:
复制
纠错
相关题目
【单选题】 派生类的构造函数的成员初始化列表中,不能包含()。
①  基类的构造函数
②  派生类中子对象的初始化
③  基类的子对象初始化
④  派生类中一般数据成员的初始化
【单选题】 派生类的构造函数的成员初始化列表中,不能包含()。
①  基类的构造函数
②  派生类中子对象的初始化
③  基类的子对象初始化
④  派生类中一般数据成员的初始化
【单选题】 假定AA为一个类,inta()为该类的一个成员函数,若该成员函数在类定义体外定义,则函数头为()
①  intAA::a()
②  intAA:a()
③  AA::a()
④  AA::inta()
【单选题】 下列的各类函数中,( )不是类的成员函数
①  构造函数
②  析构函数
③  友元函数
④  复制构造函数
【单选题】 下列的各类函数中,( )不是类的成员函数
①  构造函数
②  析构函数
③  友元函数
④  复制构造函数
【单选题】 关于类的静态成员函数描述错误的是( )
①  在创建对象前不存在
②  不能说明为虚函数
③  不能直接访问非静态函数
④  不是对象的成员
【单选题】 关于类的静态成员函数描述错误的是( )
①  在创建对象前不存在
②  不能说明为虚函数
③  不能直接访问非静态函数
④  不是对象的成员
【单选题】 下列不是描述类的成员函数的是()
①  构造函数
②  析构函数
③  友元函数
④  拷贝构造函数
【单选题】 下面选项中不是类成员函数的是
①  构造函数
②  析构函数
③  友元函数
④  静态函数
【单选题】 下面选项中不是类成员函数的是
①  构造函数
②  析构函数
③  友元函数
④  静态函数
随机题目
【单选题】 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.
【单选题】 the old couple decided to ____ a boy and a girl though they had three of their own.
①  adapt
②  bring
③  receive
④  adopt
【单选题】 I will count three hundred and not one of you ______ move a bit.
①  is to
②  are to
③  is
④  are