摘要:
1.java中有Thread 和 Runnable两种实现线程的方式。 package thread;public class MyThread extends Thread{private String name;private int tick = 10;public MyThread(String name){this.name = name;}public void run (){for(int i = 1;i 0)System.out.println(this.name + tick--);}}public static void main(String[] args) {MyRun 阅读全文