Aufgabe 1.2 bearbeitet

This commit is contained in:
romanschenk37
2022-03-03 14:37:26 +01:00
parent 526808525a
commit a45557ddfb
2 changed files with 4 additions and 3 deletions
@@ -3,7 +3,7 @@ package ch.zhaw.prog2.printer;
public class PrinterB {
// test program
public static void main(String[] arg) {
public static void main(String[] arg) throws InterruptedException {
Thread threadA = new Thread(new PrinterRunnable("PrinterA", '.', 10));
threadA.start();
@@ -11,9 +11,9 @@ public class PrinterB {
threadB.start();
while(threadA.isAlive() || threadB.isAlive()){
Thread.sleep(10);
}
System.out.println("Ende Main Thread");
System.out.println("Ende Main Thread asdf");
}