【单选题】【消耗次数:1】
访问修饰符作用范围由大到小是( )
private-default-protected-public
public-default-protected-private
private-protected-default-public
public-protected-default-private
参考答案:
复制
纠错
相关题目
【单选题】 声明成员变量时,如果不使用任何访问控制符(public, protected, private),则以下哪种类型的类不能对该成员进行直接访问 ( )
①  同一类
②  同一包中的子类
③  同一包中的非子类
④  不同包中的子类
【单选题】 下面对protected修饰符说法正确的是
①  只能在派生类中访问
②  只能在所属的类中访问
③  能在当前应用程序中访问
④  能在所属的类或派生类中访问
【单选题】 在哪种派生方式中,派生类可以访问基类中的protected成员( )
①  public和private
②  public和protected
③  protected和private
④  仅protected
【单选题】 在哪种派生方式中,派生类可以访问基类中的protected成员( )
①  public和private
②  public和protected
③  protected和private
④  仅protected
【单选题】 关于被私有访问控制符private修饰的成员变量,以下说法正确的是( )
①  可以被三种类所引用:该类自身、与它在同一个包中的其他类、在其他包中的该类的子类
②  可以被两种类访问和引用:该类本身、该类的所有子类
③  只能被该类自身所访问和修改
④  只能被同一个包中的类访问
【单选题】 下列哪种类成员修饰符修饰的变量只能在本类中被访问?( )
①  protected
②  public
③  default
④  private
【单选题】 Will you see to _____ that the flowers are well protected during the rainy season?
①  it
②  me
③  /
④  yourself
【单选题】 如没有使用private关键字定义类的数据成员,则默认为( )
①  private
②  public
③  protected
④  friend
【单选题】 如没有使用private关键字定义类的数据成员,则默认为( )
①  private
②  public
③  protected
④  friend
【单选题】 在过程定义时,Private表示( ) 。
①  此过程可以被其它过程调用
②  此过程不可以被任何其它过程调用
③  此过程只可以被本工程中其它过程调用
④  此过程只可以被本模块中其它过程调用
随机题目
【单选题】 Thecityisdeveloping_______andpropertyinthecenterisbecomingmoreexpensive.
①  rapid
②  rapidly
③  quick
④  gradual
【单选题】 _______itisyou’vefound,youmustgiveitbacktothepersonitbelongsto
①  That
②  What
③  Whatever
④  However
【单选题】 Manypeoplehavethe______thatwealthisthechiefsourceofhappiness
①  illusion
②  imagination
③  vision
④  impression
【单选题】 Strict______measureshavebeentakenduringthePresident’svisit.
①  secure
②  security
③  safe
④  save
【单选题】 Theredroseisher______.
①  favor
②  favorite
③  like
④  best
【单选题】 Therearetwonewhotelsunder______.
①  oven
②  built
③  shape
④  construction
【单选题】 She______comeyesterday.
①  do
②  have
③  did
④  does
【单选题】 Manypeople_______theirincome.
①  budget
②  isbudgeting
③  tobudget
④  istobudget
【单选题】 Yesterdaywas_______beautifulday________wedecidedtogoswimming.
①  such…that
②  so…that
③  sucha…that
④  aso…that
【单选题】 Henever________beinglookedonasastupidstudent.
①  brains
②  heads
③  minds
④  wits