Find the middle node of a LinkedList
My solution to the coding problem to find the middle node of a LinkedList in Javascript. Middle Node of a LinkedList /* LinkedList node */ class Node { constructor(data, next) { this.data = data; this.next = next; } } function printMiddle(head) { if (!head) console.log(“Empty List”); let slowPtr = head; Read more


