Study Display 4.4 (2nd ed. and 3rd ed.) or Display 4.2 & Display 4.3 (1st ed.) and then
1. Comment out date.setDate(6, 17, year); by // date.setDate(6, 17, year);
2. At the next line below, add date.readInput();
3. Run the program again. Fix any problems you may encouter along the way.
4. At the last line of your program, add System.out.println(date.month);
and see what happens. Why?
執行錯誤,因為privte是私密內容,將其改成public就可以了!
導覽連結: 首頁 -> 標題: Homework 11/16/2007: lab class definition 2
2007年11月30日 星期五
Homework 11/16/2007: lab class definition 2
ARTICLE LABELS: Java
訂閱:
張貼留言 (Atom)
0 COMMENT:
張貼留言