Pregunta de entrevista de Amazon

A leetcode linked list question on manipulating prev and next pointers