NEC Corporation Interview Question

reverse a linked list