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

Queues - Kayla Kubicke - js-scrabble #43

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

Queues - Kayla Kubicke - js-scrabble #43

wants to merge 26 commits into from

Conversation

ghost
Copy link

@ghost ghost commented May 19, 2017

JS Scrabble

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? Any time I learn something, it changes the way I approach things in the future so it is hard to answer this question. I think the googling skills I learned during ruby were particularly helpful during this project.
What was a challenge you were able to overcome on this assignment? I struggled with the prototype function highestScoreFrom. I figured it out but if I had time I would refactor the function.
What is your favorite thing about learning a new programming language? I always enjoy problem solving when learning a new language.
What is your least favorite thing about learning a new programming language? Getting stuck on a small error because you don't have enough knowledge to quickly debug.
Do you have any recommendations on how we could improve this project for the next cohort?

Kayla and others added 24 commits May 16, 2017 14:50
A word score's is calculated based on individual letters.
Scrabble word returns a score.
An array can be passed through a function and words are sorted based
on their individual score.
In the simple case that the last word is the highest scoring, that word
is returned.
This function runs before the others to avoid running through
unnecessary operations.
If multiple words have the same high earning score, an array collection is created.
This array can be used to evaluate the length of the highest earning words.
A winning word can be chosen among other high earning words.
The first 7 letter word is automatically the winner.
If none of the words are 7 letters, the shortest word with the
lowest index is chosen.
Player object has a name, an array that will contain any words they
play, and creates a new Scrabble object so that prototype functions
can be called on either a word or an array of words.
Added prototype function that adds an individual word to
word collection array.
Removed notes and cleaned up scrabble.js.
Prototype function totalScore grabs an array of words, calculates
the total score, and returns the total score.
Prototype function hasWon returns true or false based on
player's score.
Prototype function play returns false if a player has already won the game.
Worked with Noam to reduce amount of code in score function.
Reduced amount of code used to calculate the highest scoring word.
Removed sort loop from highestScoreFrom as it was unnecessary.
Removed initial value from reduce loop in highestScoreFrom because it will grab the first element as it's initial value.
Added rules and changed variable names to increase readability.
Cleaned up logic.
Fixed highestScoreFrom bug; first 7 letter word will be returned.
@PilgrimMemoirs
Copy link

JS Scrabble

What We're Looking For

Feature Feedback
Core Requirements
Git hygiene Well Done
Comprehension questions Well Done
General
score calculates score, has appropriate params and return value Well Done
highestScoreFrom calculates highest scoring word, has appropriate params and return value Well done
Player object
Has name and plays properties Well Done
Has play, totalScore, hasWon functions Well Done
Has highestScoringWord and highestWordScore functions Well Done
Overall
Submission is complete and meets expectations of this project. Great work!

Kayla and others added 2 commits May 31, 2017 11:21
Reintroduced 'i' into regular expressions based on Noam's suggestions. (I misunderstood their purpose.)
First shortest word with the highest score is returned in cases where the winning word is not seven characters long and multiple words have the same length and score.
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.

1 participant