题目
设有下面两个类的定义:
classPerson{
classStudentextendsPerson{
longid;//身份证号
intscore;//入学总分
Stringname;//姓名
intgetScore(){
)
returnscore;
}
}
则类Person和类Student的关系是
- A.包含关系
- B.继承关系
- C.关联关系
- D.上述类定义有语法错误
提示:未搜索到的试题可在搜索页快速提交,您可在会员中心"提交的题"快速查看答案。
答案
查看答案
搜题