移动端

  • 题王微信公众号

    题王微信公众号

    微信搜“题王网”真题密题、最新资讯、考试攻略、轻松拿下考试

单选题

Given the uncompleted code of a class:     class Person {  String name, department;     int age;  public Person(String n){  name = n; }  public Person(String n, int a){  name = n;  age = a;  }  public Person(String n, String d, int a) {  // doing the same as two arguments version of constructor     // including assignment name=n,age=a    department = d;     }     }  Which expression can be added at the "doing the same as..." part of the constructor?() 

发布日期:2021-06-22

Given the uncompleted code of a class:     class P...
A

Person(n,a);

B

this(Person(n,a));

C

this(n,a);

D

this(name,age);

标签: "暂无标签"

题王网让考试变得更简单

扫码关注题王,更多免费功能准备上线!