多項(xiàng)選擇題

Given the following interface definition, which definitions are valid?()  
interface I {  
void setValue(int val);  
int getValue(); 
 }   
DEFINITION a:  
(a) class a extends I {  int value;  
void setValue(int val) { value = val; 
}  
int getValue() { 
return value;
 }  
}  
DEFINITION b:  
(b) interface b extends I {  
void increment(); 
 }  
DEFINITION c:  
(c) abstract class c implements I {  
int getValue() {
 return 0; 
}  abstract void increment();  
}  
DEFINITION d:  
(d) interface d implements I {  void increment();  }  
DEFINITION e:  
(e) class e implements I {  int value;  
public void setValue(int val) { value = val; }  }  

A.Definition a.
B.Definition b.
C.Definition c.
D.Definition d.
E.Definition e.

微信掃碼免費(fèi)搜題