由买买提看人间百态

topics

全部话题 - 话题: somelist
(共0页)
b***y
发帖数: 2799
1
来自主题: Programming版 - [合集] how to copy a list?
☆─────────────────────────────────────☆
kindom (天道酬勤) 于 (Fri Sep 23 15:20:58 2005) 提到:
Sorry I could not input Chinese here.
For example, I have a list defined as:
////////////////////////////////////////
typedef std::list IntList;
struct SOMESTRUCT {
IntList * ants;
int num;
};
typedef std::list SomeList;
////////////////////////////////////////
I defined a list of type SomeList in the code:
SomeList * platoon = new SomeList();
Then I put some elements of type SOMESTRU
(共0页)