example431.cpp

来自「Data Abstraction & Problem Solving with 」· C++ 代码 · 共 24 行

CPP
24
字号
#include "ListI.h"#include <iostream>using namespace std;int main(){   List aList;   ListIterator i = aList.begin();   for (int j=1; j<=5; j++)    {      i = aList.insert(i, j);   }  // end for      i = aList.begin();   while (i != aList.end())   {      cout << *i << " ";      ++i;   }  // end while   cout << endl;   return 0;}  // end main

⌨️ 快捷键说明

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