Added lastNode method to Node struct