Grab interview question

linked list codility question given a string return in reverse order