hit-the-emojy.py 824 B

123456789101112131415161718192021222324252627282930
  1. # 🚨 Don't change the code below 👇
  2. row1 = ["⬜️","⬜️","⬜️"]
  3. row2 = ["⬜️","⬜️","⬜️"]
  4. row3 = ["⬜️","⬜️","⬜️"]
  5. map = [row1, row2, row3]
  6. print(f"{row1}\n{row2}\n{row3}")
  7. while True:
  8. position = input("Choose your emoji ")
  9. coordinates = [int(position[0]) - 1, int(position[1]) - 1]
  10. if coordinates[0] < len(map) and coordinates[1] < len(row1):
  11. break
  12. # 🚨 Don't change the code above 👆
  13. #Write your code below this row 👇
  14. emoji1 = ["😘", "😋", "😚"]
  15. emoji2 = ["😬", "😅", "😢"]
  16. emoji3 = ["😭", "😦", "😡"]
  17. emojis = [emoji1, emoji2, emoji3]
  18. emoji = emojis[coordinates[0]][coordinates[1]]
  19. map[coordinates[0]][coordinates[1]] = emoji
  20. #Write your code above this row 👆
  21. # 🚨 Don't change the code below 👇
  22. print(f"{row1}\n{row2}\n{row3}")