public class ProduceComsumerNew {
public static void main(String[] args) {
Mantou mantou = new Mantou();
new Thread(new Producer1(mantou,"红糖馒头"),"馒头铺1").start();
new Thread(new Producer1(mantou,"韭菜馒头"),"馒头铺2").start();
new Thread(new Producer1(mantou,"玉米馒头"),"馒头铺3").start();
new Thread(new Consumer1(mantou),"AAA").start();
new Thread(new Consumer1(mantou),"BBB").start();
new Thread(new Consumer1(mantou),"CCC").start();
}
}