Synopsys interview question

Reverse a linked list with constant space.