Upload files to "Aufgaben/PTP_1"

This commit is contained in:
2025-07-29 08:26:22 +02:00
parent ac95b23213
commit e566c9d5e2
2 changed files with 55 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
public class Verzweigung {
public static void main(String args[]){
int alter = 75;
if ( alter < 20 ) {
System.out.println("Du bist aber 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 aber alt!");
}
else {
System.out.println("Na, ganz frisch bist du auch nicht mehr!");
}
}
}