● GetAt › returns the node at given index
TypeError: Cannot set property 'next' of null
79 | let lastNode = this.getLast()
80 | let newNode = new Node(data)
> 81 | lastNode.next = newNode
| ^
82 | }
83 |
84 | getAt(index) {
at LinkedList.insertLast (linkedlist/index.js:81:5)
at Object.test (linkedlist/test.js:155:7)