-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMain.c
More file actions
344 lines (289 loc) · 8.65 KB
/
Main.c
File metadata and controls
344 lines (289 loc) · 8.65 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
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
#include <conio.h>
#include <stdio.h>
void main()
{
printf("Hello there! Welcome and I believe you are here to play a Game!\n\n");
sleep(2);
printf("Let me introduce myself, I am a very Intelligent Script made by Het Soni.\n\n");
sleep(2);
printf("So the Rules are Simple.\nWe will play a game with 20 Numbers and we will pick a number from 1,3 or 4 taking turns.\n");
sleep(2);
printf("Whoever has no numbers to pick from will lose the Game.");
sleep(4);
printf("So let's Start\n\nYou go first Good Luck!\n\n");
int a=20, b;
START:
sleep(2);
printf("\nPick Your Number : ");
scanf("%d", &b);
a = a-b;
if(b==1 && (b==1 || b==3 || b==4))
{
printf("\nGood! I choose 3");
a = a-3;
printf("\nThe remaining Number is %d", a);
}
if(b==3 && (b==1 || b==3 || b==4))
{
printf("Off to a Great Start I see..");
sleep(2);
printf("\nI'll choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(b==4 && (b==1 || b==3 || b==4))
{
printf("That is a wise choice.");
sleep(2);
printf("\nI choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(b!=1 && b!=3 && b!=4) {goto INVALID;}
sleep(2);
printf("\n\nEnter Your Number : ");
scanf("%d", &b);
a = a-b;
if(a==11 && (b==1 || b==3 || b==4))
{
printf("This Game is Fun isn't it?\n I wonder who made this..");
sleep(2);
printf("\nI choose 4");
a = a-4;
printf("\nThe remaining Number is %d", a);
}
if(a==12 && (b==1 || b==3 || b==4))
{
printf("You're Playing pretty good! Keep Going");
sleep(2);
printf("\nI choose 3");
a = a-3;
printf("\nThe remaining Number is %d", a);
}
if(a==13 && (b==1 || b==3 || b==4))
{
printf("Hmm.. Let me think. I have a good feeling about this.");
sleep(3);
printf("\nOkay, I choose 4");
a = a-4;
printf("\nThe remaining Number is %d", a);
}
if(a==14 && (b==1 || b==3 || b==4))
{
printf("I think you will be tough to beat.");
sleep(2);
printf("\nI choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(a==15 && (b==1 || b==3 || b==4))
{
printf("Going Slow is a Great strategy for many Games.");
sleep(2);
printf("\nI choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(b!=1 && b!=3 && b!=4) {goto INVALID;}
sleep(2);
printf("\n\nEnter Your Number : ");
scanf("%d", &b);
a = a-b;
if(a==3 && (b==1 || b==3 || b==4))
{
printf("That was a bad choice! What were You Thinking?");
sleep(1);
printf("\nI choose 3");
printf("\n\nYou lost! I'm too Good I Guess.");
goto END;
}
if(a==4 && (b==1 || b==3 || b==4))
{
printf("That was a really bad choice!");
sleep(1);
printf("\nI choose 4");
printf("\n\nYou lost! Maybe Try Again?");
goto END;
}
if(a==5 && (b==1 || b==3 || b==4))
{
printf("You do see where this Game is going, don't You?");
sleep(2);
printf("\nI choose 3");
a = a-3;
printf("\nThe remaining Number is %d", a);
}
if(a==6 && (b==1 || b==3 || b==4))
{
printf("\nOkay, I choose 4. Let's end this next turn, Shall we?");
a = a-4;
printf("\nThe remaining Number is %d", a);
}
if(a==8 && (b==1 || b==3 || b==4))
{
printf("You are Playing well! Keep Going.");
sleep(1);
printf("\nI choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(a==9 && (b==1 || b==3 || b==4))
{
printf("You are giving me a tough time..");
sleep(2);
printf("\nI choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(a==10 && (b==1 || b==3 || b==4))
{
printf("You are Playing well! Keep Going.");
sleep(1);
printf("\nI choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(a==11 && (b==1 || b==3 || b==4))
{
printf("\nAnd I choose 4");
a = a-4;
printf("\nThe remaining Number is %d", a);
}
if(a==13 && (b==1 || b==3 || b==4))
{
printf("You are playing pretty Good! I'll still beat you.");
sleep(2);
printf("\nI choose 4");
a = a-4;
printf("\nThe remaining Number is %d", a);
}
if(b!=1 && b!=3 && b!=4) {goto INVALID;}
sleep(2);
printf("\n\nEnter Your Number : ");
scanf("%d", &b);
a = a-b;
if(a==1 && (b==1 || b==3 || b==4))
{
printf("It was really fun playing with you! Thanks for playing.");
sleep(1);
printf("\nI choose 1");
printf("\n\nYou lost! Maybe Try Again?");
goto END;
}
if(a==3 && (b==1 || b==3 || b==4))
{
printf("That was a bad choice! What were You Thinking?");
sleep(1);
printf("\nAnd I choose 3");
printf("\n\nYou lost! I'm too Good I Guess.");
goto END;
}
if(a==4 && (b==1 || b==3 || b==4))
{
printf("That was a bad choice! What were You Thinking?");
sleep(1);
printf("\nI choose 4");
printf("\n\nYou lost! Maybe Try Again?");
goto END;
}
if(a==5 && (b==1 || b==3 || b==4))
{
printf("You do see where this Game is going, don't You?");
sleep(2);
printf("\nI choose 3");
a = a-3;
printf("\nThe remaining Number is %d", a);
}
if(a==6 && (b==1 || b==3 || b==4))
{
printf("You do see where this Game is going, don't You?");
sleep(2);
printf("\nI choose 4");
a = a-4;
printf("\nThe remaining Number is %d", a);
}
if(a==7 && (b==1 || b==3 || b==4))
{
printf("\nOkay, I choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(a==8 && (b==1 || b==3 || b==4))
{
printf("\nVery well then, I choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(b!=1 && b!=3 && b!=4) {goto INVALID;}
sleep(2);
printf("\n\nEnter Your Number : ");
scanf("%d", &b);
a = a-b;
if(a==1 && (b==1 || b==3 || b==4))
{
printf("It was really fun playing with you! Thanks for playing.");
sleep(1);
printf("\nI choose 1");
printf("\n\nYou lost! Maybe Try Again?");
goto END;
}
if(a==2 && (b==1 || b==3 || b==4))
{
printf("\nUh OH.. I don't feel so good about this..");
sleep(2);
printf(" Anyways, I choose 1");
a = a-1;
printf("\nThe remaining Number is %d", a);
}
if(a==3 && (b==1 || b==3 || b==4))
{
printf("That was a bad choice! What were You Thinking?");
sleep(1);
printf("\nI choose 3");
printf("\n\nYou lost! I'm too Good I Guess.");
goto END;
}
if(a==4 && (b==1 || b==3 || b==4))
{
printf("That was a bad choice! What were You Thinking?");
sleep(1);
printf("\nI choose 4");
printf("\n\nYou lost! Maybe Try Again?");
goto END;
}
if(a==6 && (b==1 || b==3 || b==4))
{
printf("\nOkay, so I choose 4");
a = a-4;
printf("\nThe remaining Number is %d", a);
}
if(b!=1 && b!=3 && b!=4) {goto INVALID;}
sleep(2);
printf("\n\nEnter Your Number : ");
scanf("%d", &b);
a = a-b;
if(a==0 && (b==1 || b==3 || b==4))
{
printf("\nWow! Congratulations! You actually managed to pull this victory of!\n");
sleep(1);
printf("You must be pretty intelligent to defeat me!\nHere you go this is your Reward.\n\n");
sleep(0.5);
printf("Open this link and Claim Your REWARD - https://www.youtube.com/watch?v=dQw4w9WgXcQ");
}
if(a==1 && (b==1 || b==3 || b==4))
{
printf("It was really fun playing with you! Thanks for playing.");
sleep(1);
printf("\nI choose 1");
printf("\n\nYou lost! Maybe Try Again?");
goto END;
}
INVALID:
if(b!=1 && b!=3 && b!=4)
{
printf("\nPlease Enter Valid Choice.");
goto START;
}
END:
getch();
}