#include <iostream>
#include <list>
using namespace std;

typedef list<int> IntegerList;
int main()
{
    IntegerList    intList;
    for (int i = 1; i <= 10; ++i)
       intList.push_back(i * 2);
    for (IntegerList::const_iterator ci = intList.begin(); ci != intList.end(); ++ci)
       cout << *ci << " " << endl;
    return 0;
}

 遍历器对各种运算符进行重载  

相关文章:

  • 2022-12-23
  • 2021-10-09
  • 2021-05-09
  • 2021-11-30
  • 2021-10-08
  • 2022-02-12
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-07-13
  • 2021-05-24
  • 2021-05-23
  • 2021-05-17
  • 2021-10-20
  • 2021-11-26
  • 2022-12-23
相关资源
相似解决方案