Solution for Nth to last element in linked list