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

Branches - Michaela & Angele #17

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

Conversation

michaela260
Copy link

Adagrams

Congratulations! You're submitting your assignment.

Comprehension Questions

Feature Feedback
What are the components that make up a method? Method signature (includes the name and parameters), method body, and return statement.
What are the advantages of using git when collaboratively working on one code base? Using git allowed both of us to access the most updated version of the file (since last push) from our own machine. Also, if one of us had made any changes in conflict with the other person's changes, it would have alerted us and made sure the changes were aligned
What kind of relationship did you and your pair have with the unit tests? We loved the unit tests. As soon as we learned how to use them we used it to guide and check our code. We added tests for wave 5, but not until after we had already coded the method. In the future, we would write the tests first.
Does your code use any methods from the Enumerable mixin? If so, where and why was it helpful? Yes - we use .map, .include? and .select. We found them super helpful for making and accessing data in large arrays and hashes. We considered trying to use .reduce for wave-4 (highest_score_from), but we weren't sure if it would work for multiple maximum scores, so we chose to spend time on the optional section. If we had more time we would explore how to use .reduce effectively.
What was one method you and your pair used to debug code? We mostly used rake and looked at the stack traces of the tests that failed to find where the error originated.
What are two discussion points that you and your pair discussed when giving/receiving feedback from each other that you would be willing to share? We discussed our communication styles (ask vs. guess) and how often we would switch off using the computer. We also checked in each day about how things were going and agreed on a plan for the day.

@jmaddox19
Copy link

jmaddox19 commented Aug 23, 2019

Adagrams

What We're Looking For

Feature Feedback
General
Answered comprehension questions X
Small commits with meaningful commit messages Great job with making small commits with clear messages!
Code Requirements
draw_letters method Super well written! Nice and succinct and clear :)
Uses appropriate data structure to store the letter distribution X
All tests for draw_letters pass X
uses_available_letters? method X
All tests for uses_available_letters? pass X
score_word method X
Uses appropriate data structure to store the letter scores X
All tests for score_word pass X
highest_score_from method X
Appropriately handles edge cases for tie-breaking logic X
All tests for highest_score_from pass X
Overall Great!!!

Wow! You even wrote your own tests for Wave 5! Great job! Super cool that y'all agreed on a plan for the day together every day. I could stand to learn from that. Haha.

Love that you used one data structure to store the quantities of the letters and the scores for the letters. Super efficient 👏

Great job y'all!!!


def return_letter_pool_hash

letter_pool_hash = {

Choose a reason for hiding this comment

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

This is great just as it is! I just wanted to mention for the future that this is usually a great example of when a global variable (ie. LETTER_POOL_HASH = ...). That way you wouldn't need to write a method and then gets called several times and a new copy of the hash wouldn't get created each time.


else

copy_of_hand = letters_in_hand.clone

Choose a reason for hiding this comment

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

This method looks great! I just wanted to name that this line isn't necessary as the copy_of_hand variable as soon as the method returns on the next line. If that short explanation isn't clear, feel free to ask a fellow student or one of us instructors to get clarity on that.

end
end

min_length = highest_scores_hash.map { |word, score| word.length }.min

Choose a reason for hiding this comment

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

This is a super clever and interesting way to do this!

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.

3 participants