/**
* 第二种 同步函数
* */
public class Thread0004 {
public static void main(String[] args) {
ThreadTest1 t = new ThreadTest1();
Thread t1 = new Thread(t);
Thread t2 = new Thread(t);
Thread t3 = new Thread(t);
t1.start();
t2.start();
t3.start();
}
}
class ThreadTest1 implements Runnable {
private static int tick = 100;