-
Notifications
You must be signed in to change notification settings - Fork 0
/
Guessـtheـword.py
347 lines (252 loc) · 11 KB
/
Guessـtheـword.py
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
345
346
347
#hidden game
def hidden_game():
#hidden mod coming soon to update 2
print("*****welcome to the hidden game***** ... \n If you are at this stage, congratulations on finishing the game, please read the help :)")
hidden_game_menu=input("menu ...\n type : play or help ?--->")
if hidden_game_menu == "help":
print("In this part\n you have to put together all the sentences\n that you have obtained in the game to get the main sentence ...\n Good luck and try to have fun :)")
elif hidden_game_menu == "play":
return
def help_word(wordkey):
print("-----------------------------------------------------------------------")
print(f"You must find the word {wordkey} among the given letters at this stage")
print("and for exit the mode game just type exit :)")
return input(".......enter.......")
def true_words(data,mylist):
mylist=[]
while True:
data=input("-- You have already found this word --")
print("--------------------")
if data in mylist :
print("---")
continue
else:
mylist.append(data)
break
def passmision(words):
print("*******************")
print(f"The stage is over ... The words found in this stage ...{words}... ")
print("*******************")
#welcome to game Guess the word
print("**********wellcome to Guess the word game*************")
#menu
while(1):
menu=input("menu...(---Type the desired option---)\n start ... help...exit:")
# code on menu
if menu == "start":
print("go to game...")
break
# if menu (help commond)
elif menu == "help":
print("*****The structure of the game is very similar to the Iranian game (Aq Mirza).In this game. You have three easy modes. There are medium and hard, in the easy case you have 3 steps, in the middle 5 steps and in the hard 10 steps, and next to these options there is a hidden option that you have to open with a secret code \n (At each step, if you need help, just write the word help)... have fun****")
continue
# if menu for exit game
elif menu =="exit":
print("see you later .. :>")
exit()
break
#level1
words_easy_1=[]
word_easy_1= 0
#level2
words_meduim=[]
word_meduim= 0
#level 3
words_hard=[]
word_hard=0
while(2):
modes=input("select your mode game \n easy ... meduim ... hard ... hidden mode (hm)...guessrd words (type : gw ) :")
# modes is easy
if modes == "easy":
while (1111):
print(f"... E I E F ... words :{words_easy_1} number word {word_easy_1} ((---help---))")
seleasy=input(f"---->")
if word_easy_1 == 3 :
passmision(words_easy_1)
break
#exit mode game
elif seleasy == "exit":
print(f"exit the {modes} mode")
break
#word in list
if seleasy in words_easy_1 :
true_words(seleasy,words_easy_1,)
continue
#word 1
elif seleasy == "evil":
print("true word :)")
word_easy_1 +=1
words_easy_1.append(seleasy)
continue
#word 2
elif seleasy == "life":
print("true word :)")
word_easy_1 +=1
words_easy_1.append(seleasy)
continue
#word 3
elif seleasy == "five":
print("true word :)")
word_easy_1 +=1
words_easy_1.append(seleasy)
continue
#help commond
elif seleasy == "help":
help_word(3)
continue
else:
print("////The entered word is incorrect////")
continue
elif modes == "meduim" or modes == "medum":
while (1112):
print(f"... M S I T G A E O L R ... words :{words_meduim} number word {word_meduim} ((---help---))")
selmedu=input(f"---->")
if word_meduim == 5 :
passmision(words_meduim)
break
#exit the mode game
elif selmedu == "exit":
print(f"exit the {modes} mode")
break
#word in list
if selmedu in words_meduim :
true_words(selmedu,words_meduim)
continue
#word 1
elif selmedu == "setting":
print("true word :)")
word_meduim +=1
words_meduim.append(selmedu)
continue
#word 2
elif selmedu == "tools":
print("true word :)")
word_meduim +=1
words_meduim.append(selmedu)
continue
#word 3
elif selmedu == "messages":
print("true word :)")
word_meduim +=1
words_meduim.append(selmedu)
continue
#word 4
elif selmedu == "email":
print("true word :)")
word_meduim +=1
words_meduim.append(selmedu)
continue
#word 5
elif selmedu == "smart":
print("true word :)")
word_meduim +=1
words_meduim.append(selmedu)
continue
#help commond
elif selmedu == "help":
help_word(5)
continue
else:
print("////The entered word is incorrect////")
continue
elif modes=="gw":
print(f"is Guessed Words is {print(list(words_easy_1+words_meduim+words_hard))}")
input("enter for go to menu....>")
continue
elif modes == "hard":
while (1114):
print(f"... L E A R N M O U G \n W A T F C H X Z K ... words :{words_hard} number word {word_hard} ((---help---))")
selhard=input("---->")
if word_hard == 10 :
passmision(words_hard)
break
#exit the mode game
elif selhard == "exit":
print(f"exit the {modes} mode")
break
#word in list
if selhard in words_hard :
true_words(selhard,words_hard)
continue
#word 1
elif selhard == "learn":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 2
elif selhard == "lemon":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 3
elif selhard == "rung":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 4
elif selhard == "waterfall":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 5
elif selhard == "code":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 6
elif selhard == "python":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 7
elif selhard == "linux":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 8
elif selhard == "glue":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 9
elif selhard == "minimize":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#word 10
elif selhard == "dark":
print("true word :)")
word_hard +=1
words_hard.append(selhard)
continue
#help commond
elif selhard == "help":
help_word(10)
continue
else:
print("////The entered word is incorrect////")
continue
elif modes == "exit":
ifexit=input("exit the game ... ?:)")
if ifexit == "yes":
input("see you :)")
break
elif ifexit == "no":
print ("ok back to menu ...")
continue
else:
print("just type yes or no ....")
input("---")
continue
elif modes == "hm":
print("coming soon :)")
continue