<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title>动画算法与数据结构</title>
    <link rel="stylesheet" href="/asserts/stylesheets/main.css" type="text/css" media="all"/>
</head>

<div class="pseudo_code">

<pre>
class Node:
    Node *prev
    Node *next
    key

class LinkedList:
    Node *sentinel  # 哨兵

    # 初始化为空链表
    init():
        sentinel &larr; 生成节点
        sentinel.next &larr; 