知道java可以使用java.util.concurrent包下的 CountDownLatch ExecutorService Future Callable 实现并行编程,并在并行线程同步时,用起来十分简单的一种 .实现原理: 1.CountDownLatch 统计并行线程完成数,并提供了await()方法,实现等待所有并行线程完成,或者指定最大等待时间.2.ExecutorService提供了execute(Callable)执行线程方法,还提供了submit(Callable)提交线程.