printElements() {
let currentNode = this.front;
let output ='';
while (currentNode) {
output = ` ${output}${currentNode.value} -> ` ;
currentNode = currentNode.next;
}
console.log(`${output}null`);
return true
}
}
//if you find this answer is useful ,
//upvote ⇑⇑ , so can the others benefit also . @mohammad alshraideh ( ͡~ ͜ʖ ͡°)