1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
|
public class Tage
{
public static String wochentag(int tag){
int i = 0;
switch(i){
case 0:
System.out.println("Kein Tag definiert");
break;
case 1:
System.out.println("Montag");
break;
case 2:
System.out.println("Dienstag");
break;
case 3:
System.out.println("Mittwoch");
break;
case 4:
System.out.println("Donnerstag");
break;
case 5:
System.out.println("Freitag");
break;
case 6:
System.out.println("Samstag");
break;
case 7:
System.out.println("Sonntag");
break;
default:
System.out.println("Geben sie eine Zahl zwischen 1-7 an");
}
}
}
|