enum Grade{
A("100-90"),B("89-80"),C("79-60"),D("59-0");//object
private String value;
private Grade(String value){
this.value=value;
}
public String getValue(){
return this.value;
}
}
//可变参数
public class Demo4{
public vode tesSum(){
sum(1,2,3,4);
}
public vode sum(int ...nums){
int sum =0;
for(int i:nums){
sum+=i;
}
System.out.println(sum);
}
}