<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="zh-TW">
		<id>https://fgchen.com/wiki/index.php?action=history&amp;feed=atom&amp;title=SCJP_1.6%E7%89%88%E8%80%83%E9%A1%8C_043</id>
		<title>SCJP 1.6版考題 043 - 修訂歷史</title>
		<link rel="self" type="application/atom+xml" href="https://fgchen.com/wiki/index.php?action=history&amp;feed=atom&amp;title=SCJP_1.6%E7%89%88%E8%80%83%E9%A1%8C_043"/>
		<link rel="alternate" type="text/html" href="https://fgchen.com/wiki/index.php?title=SCJP_1.6%E7%89%88%E8%80%83%E9%A1%8C_043&amp;action=history"/>
		<updated>2026-05-23T15:42:37Z</updated>
		<subtitle>本 Wiki 上此頁面的修訂歷史</subtitle>
		<generator>MediaWiki 1.29.0</generator>

	<entry>
		<id>https://fgchen.com/wiki/index.php?title=SCJP_1.6%E7%89%88%E8%80%83%E9%A1%8C_043&amp;diff=1386&amp;oldid=prev</id>
		<title>Ikk：新頁面:  1. class Plant{  2.   private String name;  3.   public Plant(String name){this.name = name;}  4.   public String getName(){return name;}  5. }  6. public class Tree extends Plant{  7...</title>
		<link rel="alternate" type="text/html" href="https://fgchen.com/wiki/index.php?title=SCJP_1.6%E7%89%88%E8%80%83%E9%A1%8C_043&amp;diff=1386&amp;oldid=prev"/>
				<updated>2013-03-30T07:43:38Z</updated>
		
		<summary type="html">&lt;p&gt;新頁面:  1. class Plant{  2.   private String name;  3.   public Plant(String name){this.name = name;}  4.   public String getName(){return name;}  5. }  6. public class Tree extends Plant{  7...&lt;/p&gt;
&lt;p&gt;&lt;b&gt;新頁面&lt;/b&gt;&lt;/p&gt;&lt;div&gt; 1. class Plant{&lt;br /&gt;
 2.   private String name;&lt;br /&gt;
 3.   public Plant(String name){this.name = name;}&lt;br /&gt;
 4.   public String getName(){return name;}&lt;br /&gt;
 5. }&lt;br /&gt;
 6. public class Tree extends Plant{&lt;br /&gt;
 7.   public void growFruit(){}&lt;br /&gt;
 8.   public void dropLeaves(){}&lt;br /&gt;
 9. }&lt;br /&gt;
 &lt;br /&gt;
 &lt;br /&gt;
 What statement is true?&lt;br /&gt;
   A. The code will compile without changes.&lt;br /&gt;
   B. The code will compile if public Tree(){Plant();} is added to the Tree class.&lt;br /&gt;
   C. The code will compile if public Plant(){Tree();} is added to the Plant class.&lt;br /&gt;
   D. The code will compile if public Plant(){this(&amp;quot;fern&amp;quot;);} is added to the Plant class.&lt;br /&gt;
   E. The code will compile if public Plant(){Plant(&amp;quot;fern&amp;quot;);} is added to the Plant class.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div class=&amp;quot;toccolours mw-collapsible mw-collapsed&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;font-size:medium;&amp;quot;&amp;gt;解答&amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
----&lt;br /&gt;
&amp;lt;div class=&amp;quot;mw-collapsible-content&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;span style=&amp;quot;font-size: medium;&amp;quot;&amp;gt;Ans: D   &amp;lt;/span&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;span style=&amp;quot;font-size:medium;&amp;quot;&amp;gt; 解說:&lt;br /&gt;
Tree的預設建構子有super()，父類別必須有無參數的建構子&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/span&amp;gt;	&lt;br /&gt;
&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
{{SCJP 1.6版考題講解}}&lt;/div&gt;</summary>
		<author><name>Ikk</name></author>	</entry>

	</feed>