欢迎光临散文网 会员登陆 & 注册

邢不行量化 A股Python量化课程

2022-11-12 20:35 作者:三国尽归许佳琪  | 我要投稿

for (int i = 0; i < 10; i++) {      int finalI = i;      new Thread(() -> {        int second = new Random().nextInt(10);        try {          Thread.sleep(second * 1000);        } catch (InterruptedException e) {          throw new RuntimeException(e);        }        System.out.println("线程" + finalI + "活干完了");        latch.countDown();      }).start();    }    latch.await();    System.out.println("我是老板,所有工人的活都干完了");  }}

邢不行量化 A股Python量化课程的评论 (共 条)

分享到微博请遵守国家法律