java有父線程子線程這樣的說法么?
2 回答

qq_笑_17
TA貢獻1818條經(jīng)驗 獲得超7個贊
有的,main就是父線程,Thread t就是子線程
public static void main(String[] args) throws InterruptedException
{
Thread t = new Test1();
t.start();
Thread.sleep(5000);
System.out.println("Main End");
}
添加回答
舉報
0/150
提交
取消