Amazon Interview Question

I asked to inverse a linked list.