Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package tp05;
- public class HiloD extends Thread{
- public HiloD() {}
- public void run() {
- RegionCritica cuenta = new RegionCritica();
- for(int i=1;i<=40;i++) {
- Deposito hiloD = new Deposito(cuenta);
- hiloD.start();
- try {
- sleep(30);
- } catch (InterruptedException e) {
- // TODO: handle exception
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement