看板 [ java ]
討論串[問題] 關於建構子與繼承
共 4 篇文章
首頁
上一頁
1
下一頁
尾頁

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者langrisser.時間19年前 (2006/09/14 02:01), 編輯資訊
0
0
0
內容預覽:
引述《Taique.bbs@ptt.cc (阿薩布魯‧湖瀾)》之銘言:. > ============================================================. > class B extends A{. > private int x,y;. > B(i
(還有654個字)

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者oishii.時間19年前 (2006/09/12 16:32), 編輯資訊
0
0
0
內容預覽:
引述《Taique.bbs@ptt.cc (阿薩布魯‧湖瀾)》之銘言:. 由於有任一明確的constructor存在, 不會有default constructor. --. ╭──── Origin:<不良牛牧場> bbs.badcow.com.tw (210.200.247.200)────

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者king08 (糊塗蛋)時間19年前 (2006/09/11 23:44), 編輯資訊
0
0
0
內容預覽:
Default constructor 只有在未設定Constructor 時才會自動幫你補上去. 你在class A就已經給自定的Constructor,所以就沒Default的Constructor. --. 發信站: 批踢踢實業坊(ptt.cc). ◆ From: 61.225.206.1

推噓0(0推 0噓 0→)留言0則,0人參與, 最新作者Taique (阿薩布魯‧湖瀾)時間19年前 (2006/09/11 23:25), 編輯資訊
0
0
0
內容預覽:
============================================================. class B extends A{. private int x,y;. B(int x, int y){. this.x=x;this.y=y;}. void printX
(還有299個字)
首頁
上一頁
1
下一頁
尾頁