package Nov2016; public class Ques1104 { private String num; public void setNum(String num){ num = num; // 1 this.num = num; // 2 } public String getNum(){ return num; } }
今日問題:
注釋1和2兩處的作用是否一樣?(點擊以下“【Java每日一題】20161104”查看20161103問題解析)
題目原發布於公眾號、簡書:【Java每日一題】20161104,【Java每日一題】20161104
每日一題最新將在公眾號發布,歡迎訂閱,交流進步