一个带后空结点的整齐链表
A Neat Linked Queue with the Rear Blank Node
摘要:
我们介绍一个非常简单的队列实现与单链表。在后端空白节点的帮助下,而不是通常的头节点,我们避免了额外的检查步骤,在传统的实现存在了几十年的出队操作。该表示的本质是与队列操作方向相同的半开指针区间,即使在空队列情况下也能保证一致处理。队列实现的简化减少了不必要的步骤,并在排队操作的时间限制下,最大限度地减少了出队操作的步骤,从而提高了实时系统的性能。我们将链表扩展为循环链表,循环链表也可以用来实现栈,利用循环链表中单向的最大信息,实际上构造了输出受限的双端队列。我们还提出了一个变体:惰性循环链接队列,它在某些特殊情况下更有效,特别是对于出队操作。
英文摘要:
We introduce a very simple queue implementation with the singly linked list. With the help of the rear blank node instead of the usual header node, we avoid additional check steps for the dequeue operation in the traditional implementations existing for many decades. The essence of our representation is the half-opened pointer interval with the same direction of the queue operations, which can guarantee the uniform treatment even in the empty queue case. The simplification of queue implementations cuts off unnecessary steps, and it minimizes the number of steps in the dequeue operation with the time limitation of enqueue operation, which could contribute to the performance of the real-time systems. We extend the linked queue to the circularly linked queue, which can also be used to implement stack and take advantage of the maximal information of the single direction in the circularly linked list, and it actually constructs the output-restricted deque. We also present a variant: lazy circularly linked queue, which is more efficient in some special cases, especially for the dequeue operations.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。