-
Notifications
You must be signed in to change notification settings - Fork 21
Expand file tree
/
Copy pathGCalanuga.java
More file actions
174 lines (139 loc) · 5.64 KB
/
GCalanuga.java
File metadata and controls
174 lines (139 loc) · 5.64 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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
import java.util.Scanner;
class DailyRoutine {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
System.out.print("Full Name: ");
String name = scanner.next();
System.out.print("Date: ");
String date = scanner.next();
System.out.print("==============================================================================\n");
System.out.println("Choose the Routine time (1 - for Morning, 2 - for Afternoon, 3 - Evening): ");
char timeofschedule = scanner.next().charAt(0);
timeofschedule = Character.toUpperCase(timeofschedule);
displayDailySchedule(timeofschedule);
System.out.println("That's my routine in that time ");
System.out.print("==============================================================================\n");
System.out.println("Press 1 to exit and 2 to load again" );
int schedule = scanner.nextInt();
schedule = (schedule >= 1 && schedule <= 3) ? schedule : 3;
chooseRoutine(schedule);
scanner.close();
}
private static void performActivity(String activity) {
System.out.println("Activity: " + activity);
}
private static void displayDailySchedule(char schedule) {
// Display daily schedule based on the time of routine
switch (schedule) {
case '1':
System.out.println("Morning routine");
performMorningRoutine();
wakeup();
foldTheBeddings();
cookbreakfast();
takeAbathAndChangeClothes();
eatBreakfast();
doChores();
preparinglunch();
break;
case '2':
System.out.println("Afternoon routine");
performAfternoonRoutine();
cookandeatlunch();
washdishes();
takeanap();
preparingDinner();
break;
case '3':
System.out.println("Evening routine");
performEveningRoutine();
cookandeatdinner();
washdishe();
takeanap();
cleanthemess();
takeahalfbath();
changetosleepclothes();
studyanddohomework();
preparethingsfortomorrow();
sleep();
break;
default:
System.out.println("Invalid day of the week.");
}
}
private static void chooseRoutine(int schedule) {
// Perform different routines based on the day of the week
if (schedule >= 1 && schedule <= 3) {
if (schedule == 1) {
performActivity("the routine is end");
} else if(schedule == 2 ) {
performActivity("Try to run the code again");
}
}
}
// Define activities for each day using functions
private static void performMorningRoutine() {
System.out.println("let's start early in the Morning since we have a long day ahead");
}
private static void wakeup() {
System.out.println("Wake-up at 7:00 in the Morning");
}
private static void foldTheBeddings() {
System.out.println("Fix the bed");
}
private static void cookbreakfast() {
System.out.println("Cook my breakfast");
}
private static void takeAbathAndChangeClothes() {
System.out.println("Take a Nice bath and change to my comfortable clothes");
}
private static void eatBreakfast() {
System.out.println("have my own breakfast");
}
private static void doChores() {
System.out.println("Do the Household Chores");
}
private static void preparinglunch() {
System.out.println("Prepare my Lunch");
}
private static void performAfternoonRoutine() {
System.out.println("After a hardwork, there's a time for leisure in the Afternoon time.");
}
private static void cookandeatlunch() {
System.out.println("After Preparing, i cook and eat my lunch.");
}
private static void washdishes() {
System.out.println("wash my dishes");
}
private static void takeanap() {
System.out.println(" watch movie, listening to music, playing games or Take a Nap");
}
private static void preparingDinner() {
System.out.println("Preparing for Dinner");
}
private static void performEveningRoutine() {
System.out.println("As a day comes to close, lets greet Evening by beauty and hope");
}
private static void cookandeatdinner() {
System.out.println("Cook and eat my dinner");
}
private static void washdishe() {
System.out.println("Wash dishes and cooking utensils");
}
private static void cleanthemess() {
System.out.println("Clean my own mess");
}
private static void takeahalfbath() {
System.out.println("Take my quick half bath.");
}
private static void changetosleepclothes() {
System.out.println("Choose and change into my sleeping clothes");
}private static void studyanddohomework() {
System.out.println("Study and review materials for my homework and exam.");
}private static void preparethingsfortomorrow() {
System.out.println("Prepare thee needed thongs for tomorrow such as uniforms, bags, books and etc.");
}
private static void sleep() {
System.out.println("Sleep early");
}
}