Compare commits

...

2 Commits

Author SHA1 Message Date
raidenkhan
1f2fb041d7
Merge 16d6ffc697 into d7a41a6461 2024-07-13 21:10:38 +02:00
raidenkhan
16d6ffc697
Update DoublyLinkedListNode.js 2023-09-21 12:34:24 +00:00

View File

@ -1,8 +1,9 @@
export default class DoublyLinkedListNode {
constructor(value, next = null, previous = null) {
this.value = value;
this.next = next;
this.previous = previous;
constructor(value, next = null, previous = null) {//create a constructor.
this.value = value;//the this keyword is used to refer to the object being created pretty much like a memory locatin
this.next = next;//this is to store the address of the next node
this.previous = previous;//this is to store the address of the previous node
}
toString(callback) {