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

📄 half.cpp

📁 数据结构c++语言描述 Borland C++实现
💻 CPP
字号:
// Test LinearList<T>::Half

#include <iostream.h>
#include "clist.h"

void main()
{
   // initialize two lists
   int n = 10, m = 5;
   LinearList<int> A(20), B(20);
   for (int i = 0; i < n; i++)
      A.Insert(0, 2*(n - i));
   for (int i = 0; i < m; i++)
      B.Insert(0, 2*(n - i) + 1);

   cout << "List A is" << endl;
   cout << A << endl;

   cout << "A.Half() is" << endl;
   cout << A.Half() << endl;

   cout << "List B is" << endl;
   cout << B << endl;

   cout << "B.Half() is" << endl;
   cout << B.Half() << endl;

}

⌨️ 快捷键说明

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