Javascript Convert A Singly Linked List Into An Array

Javascript Convert A Singly Linked List Into An Array