Todos os livros

Profissional

Apps Sobre Coach Entrar Começar a ler

Computer Science · Glossário

O que é Sentinel?

Definition 15.2 University Computer Science — Year 1 · Capítulo 15 — Linked Structures: Lists, Stacks and Queues

A sentinel is a cell that holds no element and is always present. In a circular doubly linked list with a sentinel, the sentinel’s successor is the first cell, its predecessor the last, and the empty list is the sentinel pointing to itself both ways.

A circular doubly linked list with a sentinel S, empty and holding 1, 2, 3. Every cell has two neighbours, so insertion and removal never test for an end.
A circular doubly linked list with a sentinel S, empty and holding 1, 2, 3. Every cell has two neighbours, so insertion and removal never test for an end.
Ler no capítulo →