Skip to content

Instantly share code, notes, and snippets.

@jrmedina
Last active November 10, 2022 17:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jrmedina/dd3bd2878d3cb00cf12a1bc40db6c5fa to your computer and use it in GitHub Desktop.
Save jrmedina/dd3bd2878d3cb00cf12a1bc40db6c5fa to your computer and use it in GitHub Desktop.
CHALLENGE: Millions of Numbers
What worked well in your process?
Keeping the approach simple, I knew that we would have to simultaneously be iterating over two different arrays (minimum). Therefore I was able to break this problem down into two iterations which helped me keep track of the data and what was occurring.
What was difficult/where did you struggle?
The struggle I had was knowing that my initial solution wasn't the most efficient, after the recursion lesson I felt like this was a prime opportunity to implement. However, that was easier said than done - I was not able to determine what my base case would be.
What feedback/discussion did you have with your peer?
We shared our solutions and it seemed as if we all had the same approach which was a double iteration. However, Eddie's use of `new Set` was an interesting way of removing duplicates.
Is there anything you want to change about your approach to the next technical challenge?
Keeping an open mind, I approached this problem with a solution I had used before due to the scope of time. With more recursion practice this would have led to a better outcome.
-----------------------------------------------------------------------------------------------------------------------
CHALLENGE: What Did I Order?
What worked well in your process?
Reworking the prompt to what made the most sense to me. The initial prompt was a little wordy and some of the important data/takeaways got lost. Creating bullet points of the return, constraints, and data was necessary for me to keep track of my what was being asked and how I was going to do it.
What was difficult/where did you struggle?
This problem was difficult. I was able to find a solution for half of the receipts, but unfortunately, could not come up with a solution for items that had >1 quantity.
What feedback/discussion did you have with your peer?
We all agreed this was a hard challenge and that recursion was needed in order to resolve receipts with >1 quantity of items. The sorting of the data, and filtering out items that were greater than the receipt total helped minimize the possible data.
Is there anything you want to change about your approach to the next technical challenge?
Again, recursion. This was a great use case for a recursive approach. I am still working through this during my free time as practice.
-----------------------------------------------------------------------------------------------------------------------
CHALLENGE: Robot
What worked well in your process?
Pattern Recognition, pseudo coding, and a lot of console logs.
What was difficult/where did you struggle?
Trying to do much functionality at once, was a problem that had to be broken down very granular and needed multiple parts to be achieved.
What feedback/discussion did you have with your peer?
Pseudo-coding was a must for me this time, I knew the initial approach would consider assigning each movement with a numeric value but I needed to find the solution if my peers didn't insist on me pseudo-coding and rubber-ducking my thought process.
Is there anything you want to change about your approach to the next technical challenge?
Articulating my process while writing code simultaneously.
-----------------------------------------------------------------------------------------------------------------------
TAKEAWAYS:
What do you want to continue working on?
Pattern matching and recursion.
How will you continue working on it?
Refactoring my solutions to this week's prompts to include a recursion, keeping an open mind when approaching problems, and don't always resort to "the way I know" how it could be done.
How can you keep yourself accountable? (ex. meet with peers, meet with a mentor, continue with weekly reflections, etc.)
Continue weekly reflections, attempt one of the technical prompts daily and share/meet with my peers who are doing the same.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment