⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 llist.h

📁 经典c++程序的实现
💻 H
字号:
class list {                  // Linked list class
private:
  link* head;                 // Pointer to list header
  link* tail;                 // Pointer to last ELEM in list
  link* curr;                 // Position of "current" ELEM 
public:
  list(const int =LIST_SIZE); // Constructor
  ~list();                    // Destructor
  void clear();               // Remove all ELEMs from list
  void insert(const ELEM&);   // Insert ELEM at current position
  void append(const ELEM&);   // Insert ELEM at tail of list
  ELEM remove();              // Remove and return current ELEM
  void setFirst();            // Set curr to first position
  void next();                // Move curr to next position
  void prev();                // Move curr to previous position
  int  length() const;        // Return current length of list
  void setPos(const int);     // Set curr to specified position
  void setValue(const ELEM&); // Set current ELEM's value
  ELEM currValue() const;     // Return current ELEM's value
  bool isEmpty() const;       // Return TRUE if list is empty
  bool isInList() const;      // TRUE if curr is within list
  bool find(const ELEM&);     // Find value (from current position)
};

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -