BT Group interview question

Q: Write a code to reverse a Linked List