MSCI interview question

[Data Structure]Reverse a linked list