Pergunta de entrevista da empresa Chewy

Simple linked list related problem with a small twist