-
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathswitch19.java
More file actions
81 lines (73 loc) · 1.91 KB
/
switch19.java
File metadata and controls
81 lines (73 loc) · 1.91 KB
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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
package swichcase;
import java.util.Scanner;
public class switch19 {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int n;
System.out.print("Yil:");
n = scanner.nextInt();
System.out.print("Yil: ");
switch ((n) % 10)
{
case 0:
case 1:
System.out.print("Oq ");
break;
case 2:
case 3:
System.out.print("Qora ");
break;
case 4:
case 5:
System.out.print("Yashil ");
break;
case 6:
case 7:
System.out.print("Qizil ");
break;
case 8:
case 9:
System.out.print("Sariq ");
break;
}
switch ((n + 8) % 12)
{
case 0:
System.out.print("Sichqon");
break;
case 1:
System.out.print("Sigir");
break;
case 2:
System.out.print("Yo`lbars");
break;
case 3:
System.out.print("Quyon");
break;
case 4:
System.out.print("Ajdarho");
break;
case 5:
System.out.print("ilon");
break;
case 6:
System.out.print("Ot");
break;
case 7:
System.out.print("Qo`y");
break;
case 8:
System.out.print("Maymun");
break;
case 9:
System.out.print("Tovuq");
break;
case 10:
System.out.print("It");
break;
case 11:
System.out.print("To`ngiz");
break;
}
}
}