Hulu interview question

how to reverse a linked list?

Interview Answer

Anonymous

21 Jan 2011

Traverse the list in reverse order (starting from the end). Create a new list and add the objects sequentially. Voila, the list is now reversed.