Ask your own question, for FREE!
MIT 6.00 Intro Computer Science (OCW) 44 Online
OpenStudy (python):

Is any body looking at the first word games assignment? I feel like the course didn't really create a method to analyze the list of letters

OpenStudy (python):

and create a score. In the lecture the prof goes over one type of list and doesnt explain the type given in the assignment.

OpenStudy (shadowfiend):

Is there something in particular that you want help with though? Which part doesn't make sense?

OpenStudy (python):

SCRABBLE_LETTER_VALUES = { 'a': 1, 'b': 3, 'c': 3, 'd': 2, 'e': 1, 'f': 4, 'g': 2, 'h': 4, 'i': 1, 'j': 8, 'k': 5, 'l': 1, 'm': 3, 'n': 1, 'o': 1, 'p': 3, 'q': 10, 'r': 1, 's': 1, 't': 1, 'u': 1, 'v': 4, 'w': 4, 'x': 8, 'y': 4, 'z': 10 }

OpenStudy (python):

how do I interact with this list, how do I search for the value of for example "c"

OpenStudy (python):

the example shown in the lecture had the format, L = [['un', 'one'], ['deux', 'two']]

OpenStudy (shadowfiend):

You can look up a value in a dictionary like that using []. So in the case above, SCRABBLE_LETTER_VALUES['c'] should be 3.

OpenStudy (python):

THank you very much!!

OpenStudy (shadowfiend):

No problem. Feel free to ask more questions :)

Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!
Latest Questions
Breathless: womp
41 minutes ago 0 Replies 0 Medals
Breathless: yo who wanna match pfp?
44 minutes ago 11 Replies 1 Medal
Ylynnaa: This was long time ago lmk if u fw itud83dude1d
4 hours ago 17 Replies 2 Medals
abound: Wow question cove really fell off
6 hours ago 6 Replies 1 Medal
ayden09: chat i love black pink hehe i like jones to
6 hours ago 20 Replies 2 Medals
kamani7676: help
1 day ago 5 Replies 1 Medal
Can't find your answer? Make a FREE account and ask your own questions, OR help others and earn volunteer hours!

Join our real-time social learning platform and learn together with your friends!