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 - Farah #46

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

in-formation
Copy link

ride share

Congratulations! You're submitting your assignment.

Comprehension Questions

Question Answer
What did your data structure look like at first? Did this structure evolve over time? Why? At first it was a giant mess. With the help of my classmates, I was able to reduce one level of inception/array/hashes. And that helped a ton. It was redundant and not necessary.
What was your strategy for going through the data structure and gathering information? I wanted the data to be structured around the driver. That way when a driver made a new trip, that information could theoretically could be added to their respective hash/array every time.
What was an example of something that was necessary to store in a variable? Why was it necessary, useful, or helpful? When calculated the maximum money made or highest rated average and comparing it through each driver, the best way I could visualize required me to create a new variable and store that information while it iterated through every driver to see if the maximum needed to be reassigned or not.
What kinds of iteration did you use? Did you use .map? If so, when? If not, why, or when would be a good opportunity to use it? I didn't use .map but looking back there were a couple times I created a new array such as Question 3 and 5 when evaluated average rating for the drivers. But mostly I didn't use it because I finished the assignment prior to Friday's lecture and I was not in class on Friday and thus only was able to do the reading on Enumerables and .map and I didn't feel comfortable with using .map (yet!).
Were some calculations easier than others? Why? Average is an easy calculation but finding maxs and iterating through to establish or reassign the max can sometimes get a little confusing in my head. The loop structure, I need to visualize to make sure it's correct.

@jmaddox19
Copy link

Ride Share

What We're Looking For

Feature Feedback
Answers the comprehension questions X
Readable code with consistent indentation and reasonable code style Yes, except for the 4-space indentation
Outputs the correct number of rides each driver has given X
Outputs the total amount of money each driver has made X
Outputs the average rating for each driver X
Outputs which driver made the most money X
Outputs which driver has the highest average rating X

Good job! The data structure is formatted really well and the variables are well-named.

If there were one thing I could suggest that will be helpful in the future, it would be to make use of built-in methods like map and sum when working with arrays/hashes. Everything here is spot on! You basically wrote your own versions of sum and map methods which is great to be able to do - just wouldn't want you to continue to do all that work all the time moving forward.

This is kinda nit-picky but the spacing for this assignment is set to 4 instead of 2. It's easier for us to read (and considered best practice) to space to 2. Feel free to talk to any of us or a fellow student about that if you're unsure how to do it.

I want to reiterate though, Great work!

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