nieve -> naive Just a small typo, article is good. Clear examples and good explanations.
That code is so bad. Who does this?! return ($this->head === 0 && $this->tail === $this->size - 1) || $this->head === $this->tail + 1; Or this? $return = $this->next?->resetPrevious(); Or this!!! $this->tail = $this->tail?->setNext(new Node($this->tail, null, $value))->next ?? $this->head = new Node(null, null, $value); Or leaves typos in their code? elseif ($this->tail === $this->size - 1) { $this->tail = 0;just a t…
PHP aint pretty, but that code doesn't seem unreasonable to me. I certainly wouldn't blink at it outside of the typo.