What I noticed during this part of the tech interview was that the interviewer wanted to find out wherever I understood what I was working on and how it worked, but also how I acted when there could be an improvement on a part of the system. const values = { value : 'Dog' , nextValue : { value : 'Watermelon' , nextValue : { value : 'Cat' , nextValue : { value : 'Orange' , nextValue : { value : 'Pear' , nextValue : { value : 'Apple' } } } } } } ; function getLastThreeValues ( value ) { const array = [ ] ; function getValueAndPush ( v ) { array .