作者javabug ( )
看板java
標題[問題]NullPointerException
時間Mon Apr 3 17:34:57 2006
int t_count=9;
rThread[] threads = new rThread[t_count];
for (int i=0; i<=threads.length; i++)
threads[i].start();
我只是想用陣列宣告10個thread
他一直顯示我NullPointerException
可是我不知道我到底哪裡沒有把陣列用進去
請各位大大救救我
還有我用System.out.println(threads[i]);
想檢查到底有沒有寫進去
結論當然是顯示了Null
可是卻只有9個
為什麼為什麼>"<
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 163.25.118.31