关于Java的接口,以下哪一项是正确的。
1) An interface can contain following type of members.
....public, static, final fields (i.e., constants)
....default and static methods with bodies
2) An instance of interface can be created.
3) A class can implement multiple interfaces.
4) Many classes can implement the same interface.
(A) 1、3和4
(B) 1、2和4
(C) 2、3和4
(D) 1、2、3和4答案: (A)
解释:
这个问题的测验