Get kth element from the end