就是輸出不正確啊
public class HelloWorld {
? ? public static void main(String[] args) {
char today='日';
switch(today){
? ? ? ? case '一':
? ? ? ? case '三':
? ? ? ? case '五':
? ? ? ? ? ? System.out.println("吃包子");
? ? ? ? ? ? break;
? ? ? ? case '二':
? ? ? ? case '四':
? ? ? ? case '六':
? ? ? ? ? ? System.out.println("吃油條");
? ? ? ? ? ? break;
? ? ? ? defaule:
? ? ? ? ? ? System.out.prinln("吃主席套餐");
? ? ? ? ? ?
? ? ? ? } ?
? ?}
}
error: cannot find symbol
System.out.prinln("?????");
^
symbol: method prinln(String)
location: variable out of type PrintStream
1 error
結(jié)果是這個。。。
2015-08-12
這里是default,不是defaule
這里是println,不是prinln。