Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Whales C17- Nishat Salsabil and Julie Warren Adagrams #43

Open
wants to merge 9 commits into
base: master
Choose a base branch
from

Conversation

nishatsalsabil
Copy link

No description provided.

Copy link

@jericahuang jericahuang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work on this project, Nish and Julie! The code you wrote together both passed all the tests and met the learning goals. I also made note of great highlights I saw. You both have earned a 🟢 on Adagrams!

def draw_letters():
pass
'''
input: none

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yay docstrings!

each letter in the LETTER_POOL
'''
hand = []
letter_freq = {}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent use of a dictionary to keep track of letters and their frequencies

False otherwise or if char in word is not in hand.
'''
word = word.upper()
hand_copy = copy.deepcopy(hand)

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great way to avoid side effects!

output: Returns True if each char is uniquely in hand. Returns
False otherwise or if char in word is not in hand.
'''
word = word.upper()

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! This will not introduce a side effect because strings are immutable!

played_word_dict[word] = score

highest_score = max(played_word_dict.values())
best_word_list = [key for key, value in played_word_dict.items()\

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lovely list comprehension!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants