看板
[ java ]
討論串[J2SE] 宣告 Set<String> edge[] 出了錯誤訊息
共 2 篇文章
首頁
上一頁
1
下一頁
尾頁
內容預覽:
請教各位前輩. 小弟我最近寫了一支程式. 裡面有段宣告是這樣寫的. Set<String> edge[] = new HashSet[in + 1. for (int i = 0; i < edge.length; i++. edge[i] = new HashSet<String>();. 在後面
(還有68個字)
內容預覽:
Java 不允許 generic array,因此你只能不告訴 compiler type parameter 是什麼,. 但就是因為沒有宣告,所以有 type safety 的 warning。. 首先,在 runtime 時,generic 的 type parameter 是不存在的,這叫 t
(還有1628個字)
首頁
上一頁
1
下一頁
尾頁