got the linked list to reverse iteratively as well as recursively.