backup
This commit is contained in:
25
3/Verzweigung.~ava
Normal file
25
3/Verzweigung.~ava
Normal file
@@ -0,0 +1,25 @@
|
||||
public class Verzweigung {
|
||||
public static void main(String args[]) {
|
||||
int alter = 30;
|
||||
if(alter <= 20) {
|
||||
System.out.println("Du bist noch jung");
|
||||
}
|
||||
|
||||
else if (alter < 30) {
|
||||
System.out.println("ISt noch ok!");
|
||||
}
|
||||
else if (alter < 40) {
|
||||
System.out.println("Grenzwertig :-P");
|
||||
}
|
||||
else if (alter < 50) {
|
||||
System.out.println("Die Rente ist in sicht");
|
||||
}
|
||||
else if (alter < 60) {
|
||||
System.out.println("Bist du baer alt");
|
||||
}
|
||||
|
||||
else {
|
||||
System.out.println("Na, ganz frish");
|
||||
} // end of if-else
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user