Dictionaries Scrabble Project- Syntax Error


I’m stuck on Task 9 of the Scrabble project. I keep getting a syntax error and I’m not sure what it is referring to. The full code up to the point of error is:

letters = ["A", "B", "C", "D", "E", "F", "G", "H", "I", "J", "K", "L", "M", "N", "O", "P", "Q", "R", "S", "T", "U", "V", "W", "X", "Y", "Z"]
points = [1, 3, 3, 2, 1, 4, 2, 4, 1, 8, 5, 1, 3, 4, 1, 3, 10, 1, 1, 1, 1, 4, 4, 8, 4, 10]

letters_to_points = {letters:points for letters, points in zip(letters, points)}

letters_to_points[" "]= 0

def score_word(word):
  point_total = 0
  for letters in word:
    point_total += letters_to_points.get(letters, 0)
  return point_total

brownie_points = score_word("BROWNIE")

players_to_words = {player 1: ["BLUE, TENNIS, EXIT"], wordNerd: ["EARTH, EYES, MACHINE"], Lexi Con: ["ERASER, BELLY, HUSKY"], Prof Read: ["ZAP, COMA, PERIOD"]}

The syntax error on the terminal is pointing to the comma after COMA but I’m not sure if it’s that specific bit causing the error. Until the players_to_words dictionaries was put in, the brownie_points variable was returning the correct answer, but now all the terminal shows in the syntax error for, I’m assuming, something in players_to-words.

Thank you in advance for any help.

the keys in your players_to_words dictionary are undefined variable. So either need to define these variables or make the keys strings

Thank you for your help :slight_smile: