摘要:
// 用 API 给线程起名1 public class MyThreadApi extends Thread { 2 @Override 3 public void run(){ 4 for (int i = 0; i < 5; i++) { 5 System.out.println(Thread 阅读全文
摘要:
1 // 方式一:继承Thread类 2 public class Thread{ 3 public static void main(String[] args) { 4 Thread t = new MyThread(); 5 t.start(); 6 7 for (int i = 0; i < 阅读全文