what is wrong with the following interfface
来源:学生作业帮 编辑:大师作文网作业帮 分类:综合作业 时间:2024/10/01 15:35:19
what is wrong with the following interfface
public interfface something is wrong{
void aMethod(int aValue){
System.out.println("hi mom"):
}
}
public interfface something is wrong{
void aMethod(int aValue){
System.out.println("hi mom"):
}
}
首先,你的接口关键字就错了,是interface ,你多了一个f,命名规则也错了,看下命名规则吧,不能用空格的,只能用下划线或字母或数字,并且不能数字开头;
还有,接口里面不能有方法体的大哥.
再问: 我同学考试给我发的彩信,我不懂java 能说清楚点么?
再答: 就按我的说,就知道了,是个非常非常基础的东西,估计他能看懂
再问: something is wrong我打错了,是SomethingIsWrong
再答: 接口里不能有方法体的,比如: void aMethod(int aValue){ System.out.println("hi mom"): } 这个方法是具体的,不能放在接口里,只能定义方法;改成一下就好: public interface somethingiswrong{ void aMethod(int aValue); }
还有,接口里面不能有方法体的大哥.
再问: 我同学考试给我发的彩信,我不懂java 能说清楚点么?
再答: 就按我的说,就知道了,是个非常非常基础的东西,估计他能看懂
再问: something is wrong我打错了,是SomethingIsWrong
再答: 接口里不能有方法体的,比如: void aMethod(int aValue){ System.out.println("hi mom"): } 这个方法是具体的,不能放在接口里,只能定义方法;改成一下就好: public interface somethingiswrong{ void aMethod(int aValue); }
what is wrong with the following program?
What is wrong with the kite?
What is wrong with the sentence?
What is wrong with?
what is the matter?what is wrong with celetis
Anything wrong with the following illustrative sentence?
是What is the wrong with you还是What is wrong with you?
What The Fuck Is Wrong With You 和 what's the fucking wrong w
5.Which of the following is wrong?...
Which of the following sentences is wrong?
Which of the following is wrong?
WHICH OF THE FOLLOWING IS WRONG?是什么意思