لقد عدت من جديد وبدأت من من البداية والآن وصلت إلى حيث توقفت وأريد أن أريكم حلّي لامتحان جزيرة الكنز
print(‘’’
treasure island
.-^-.
//_
| |
| |
| |
| |
/| |
/ | |
| | | |
| || |
| جزيرة |
| الكنز |
__/
‘’')
print(‘Welcome to my treasure island! ’)
print(‘There are two doors: red and green.’)
print(‘Which door would you like to open?’)
doors = input('Red or green? ').lower()
if doors == “green”:
print(‘You have chosen the wrong door. Game over! ’)
elif doors == ‘red’:
print(‘Now you have chosen the right door. ’)
print(‘You are in the room. You see three boxes: black, white, and green.’)
boxes = input('Which box do you want to open? ').lower()
if boxes == 'white':
print("Excellent! You have found the treasure! 💰")
elif boxes == 'green':
print('Oops! You have opened a box with snakes. Game over! 🐍')
elif boxes == 'black':
print('Sorry! You have opened a box with spiders. Game over! 🕷️')
else:
print('Your choice is not found. ❌')
else:
print(“Your choice is incorrect. Please choose again. ”)