问题在于17和18行代码
 
t2.start();
Thread.sleep(10);

start方法将t2线程加入到主线程的线程组中,作为他的子线程运行,将sleep(10)去掉就能避免t2线程无法使用。