多线程交替打印数字—多种实现
多线程交替打印数字—多种实现原文来自个人博客https://benym.cn使用synchronized锁实现public class Test { public static void main(String[] args) { mutilThreadPrintNum m1 = new mutilThreadPrintNum(); Thread thread1 = new Thread(m1); Thread thread2 = new Th