Skip to content

Jake Ross Solutions for back end test#50

Open
JakeJustLearning wants to merge 1 commit intoOntraport:masterfrom
JakeJustLearning:back-end-solution
Open

Jake Ross Solutions for back end test#50
JakeJustLearning wants to merge 1 commit intoOntraport:masterfrom
JakeJustLearning:back-end-solution

Conversation

@JakeJustLearning
Copy link

@JakeJustLearning JakeJustLearning commented Jul 7, 2023

This provides two solutions in JS and also aims to cover some edge cases not immediate shown in the prompt

For JS the language limits this to work accurately only if the incoming container is a plan JavaScript Object {} if it were an Array or set it would not be able to meet the criteria of mutating the original object in place without there being relics such as empty items in the beginning of the array. This is why I added validation to ensure that the incoming container was an object.

I also covered edge cases for when arrays and objects are nested within one another, Date Objects, null and undefined values. as well as when those are nested. Thank you this was fun!

@JakeJustLearning JakeJustLearning changed the title both solutions Jake Ross Solutions for back end test Jul 7, 2023
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