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

Leaves--Janice #39

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

Leaves--Janice #39

wants to merge 15 commits into from

Conversation

jaitch
Copy link

@jaitch jaitch commented Nov 18, 2019

JS Adagrams

Congratulations! You're submitting your assignment!

Comprehension Questions

Question Answer
What patterns were you able to use from your Ruby knowledge to apply to JavaScript? if and while
Did you need to use different strategies to find information online about JavaScript than you would for Ruby? Kind of...when I was looking for JS equivalents to Ruby methods, yes
What was a challenge you were able to overcome on this assignment? Being robbed of all the Ruby methods I've grown to love! I was particularly flummoxed by comparing word lengths when determining the winner--accessing to the word length from the array of objects with two key-value pairs was challenging!
What has been interesting and positive about learning a new programming language? Even though I feel like I now know neither Ruby nor JavaScript, it has been fun to approach this as translation rather than learning a whole new language. I like the brain-twisting!
What is something to focus on your learnings in JavaScript in the next week? Remembering that I can't return out of a forEach!

@beccaelenzil
Copy link

JS Adagrams

What We're Looking For

Feature Feedback
General
Answered comprehension questions yes
Small commits with meaningful commit messages yes
Code Requirements
drawLetters method
Uses appropriate data structure to store the letter distribution yes
All tests for drawLetters pass yes
usesAvailableLetters method
All tests for usesAvailableLetters pass yes
scoreWord method
Uses appropriate data structure to store the letter scores yes
All tests for scoreWord pass yes
Optional
highestScoreFrom method
Appropriately handles edge cases for tie-breaking logic yes
All tests for highestScoreFrom pass yes
Overall Great work overall! Your code is well written and you've done a good job practicing javascript syntax. I am particularly impressed by your use of helper functions. One style note is to organize your code such that all constants (the letter frequency and letter value objects, in this case) and helper functions are at the top (inside the module), and all functions are written in the order in which they are used (even though this isn't required). Keep up the hard work!

drawLetters() {
// Implement this method for wave 1

Choose a reason for hiding this comment

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

Here, you shuffle the entire array pool of letters... and then, you take the first ten. Consider refactoring this so that you randomly pick ten letters, instead of shuffling the entire array.

scoreWord,

highestScoreFrom(words) {
let wordCollection = [];

Choose a reason for hiding this comment

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

Consider using comments to outline your logic here. There's a lot going on, there may be an opportunity for a helper function.

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