Auf Thema antworten

ok, mal Schritt für Schritt

hier ist die Methode, die müsste so ja stimmen

sie wirft jetzt eine Exception und ich fange sie nicht gleich auf..


[code=Java]

public class Slipsize_too_small_Exception{


    public void text(int a) throws IllegalArgumentException{


        if (a < 120) {

            throw new IllegalArgumentException();

        } else {

            System.out.println("well done");

        }

    }

}[/code]



Oben