数据结构 顺序表(c++实现)

上传者: u012350104 | 上传时间: 2019-12-21 21:24:58 | 文件大小: 50KB | 文件类型: zip
使用c++实现的顺序表:多文件编程,层次清晰,函数有注释 SeqList();//构造函数,存储的元素个数设为0 bool setLength(size_t length);//设置已经存储的元素个数 bool addElement(ElemType element);//把某个元素添加到顺序表末尾 bool addElement(ElemType element , size_t n);//插入一个元素,使其成为第n个元素,其余元素后移 bool delElement();//删除所有的元素 bool delElement(size_t n);//删除第n个元素 bool delElement(string elementDetailType,string elementDetail);//通过某个元素细节找到元素,把这个元素删除 bool replaceElement(ElemType element , size_t n);//使用一个元素,替换掉第n个元素 bool swapElement(size_t n1 , size_t n2);//把第n1个元素和第n2个元素交换 ElemType* getElement();//得到数组头的指针 ElemType* getElement(size_t n);//得到第n个元素的指针 size_t getLength();//得到存储的元素个数 size_t getMaxSize();//得到顺序表容量 bool showElementDetail();//输出所有的元素细节 bool showElementDetail(size_t n);//输出第n个元素的细节 bool showElementDetail(string elementDetailType,string elementDetail);//通过某个元素细节找到元素,输出元素所有细节 size_t findElement(string elementDetailType,string elementDetail);//通过某个元素细节找到元素位置 static int inputAInt(int min = 0,int max = 9,int defaultValue = -1);//从键盘读取,限制为一个min到max间的整数,非法情况返回defaultValue void startControlLoop();//打开控制界面 ~SeqList();//析构函数

文件下载

资源详情

[{"title":"( 37 个子文件 50KB ) 数据结构 顺序表(c++实现)","children":[{"title":"MySeqList","children":[{"title":"MySeqList.xcodeproj","children":[{"title":"project.xcworkspace","children":[{"title":"contents.xcworkspacedata <span style='color:#111;'> 154B </span>","children":null,"spread":false},{"title":"xcuserdata","children":[{"title":"hanzijian.xcuserdatad","children":[{"title":"UserInterfaceState.xcuserstate <span style='color:#111;'> 20.75KB </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true},{"title":"xcuserdata","children":[{"title":"hanzijian.xcuserdatad","children":[{"title":"xcdebugger","children":[{"title":"Breakpoints_v2.xcbkptlist <span style='color:#111;'> 91B </span>","children":null,"spread":false}],"spread":true},{"title":"xcschemes","children":[{"title":"xcschememanagement.plist <span style='color:#111;'> 481B </span>","children":null,"spread":false},{"title":"MySeqList.xcscheme <span style='color:#111;'> 3.23KB </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true},{"title":"project.pbxproj <span style='color:#111;'> 8.59KB </span>","children":null,"spread":false}],"spread":true},{"title":".DS_Store <span style='color:#111;'> 6.00KB </span>","children":null,"spread":false},{"title":"MySeqList","children":[{"title":"ElemType.h <span style='color:#111;'> 2.12KB </span>","children":null,"spread":false},{"title":"SeqList.cpp <span style='color:#111;'> 25.98KB </span>","children":null,"spread":false},{"title":"main.cpp <span style='color:#111;'> 564B </span>","children":null,"spread":false},{"title":"ElemType.cpp <span style='color:#111;'> 8.46KB </span>","children":null,"spread":false},{"title":"SeqList.h <span style='color:#111;'> 2.01KB </span>","children":null,"spread":false}],"spread":true},{"title":".git","children":[{"title":"info","children":[{"title":"exclude <span style='color:#111;'> 40B </span>","children":null,"spread":false}],"spread":true},{"title":"index <span style='color:#111;'> 821B </span>","children":null,"spread":false},{"title":"objects","children":[{"title":"pack","children":null,"spread":false},{"title":"b5","children":[{"title":"12ed15e138f2c37bba2989f128758d1d0cbed6 <span style='color:#111;'> 336B </span>","children":null,"spread":false}],"spread":true},{"title":"16","children":[{"title":"293b665df606a0c3e86d973fd8aba61848d661 <span style='color:#111;'> 1.98KB </span>","children":null,"spread":false}],"spread":true},{"title":"info","children":null,"spread":false},{"title":"61","children":[{"title":"5edf087bf1ac1b67781808c66cef9f21158efc <span style='color:#111;'> 85B </span>","children":null,"spread":false}],"spread":true},{"title":"88","children":[{"title":"0d524fa92890c0fe2a40be1b505248221a0ce8 <span style='color:#111;'> 240B </span>","children":null,"spread":false}],"spread":true},{"title":"a5","children":[{"title":"39ef56009137988bcd17c55c9559395c3627c9 <span style='color:#111;'> 448B </span>","children":null,"spread":false}],"spread":false},{"title":"f2","children":[{"title":"4fc7792f06803eb56892eba5d7c0f2c6573808 <span style='color:#111;'> 429B </span>","children":null,"spread":false}],"spread":false},{"title":"44","children":[{"title":"cd0483e1c8a9dea280fa5c1155c9ebf9cbece4 <span style='color:#111;'> 69B </span>","children":null,"spread":false}],"spread":false},{"title":"4a","children":[{"title":"7c970b2e7667cec6aa1dd9120de6616b5ede1e <span style='color:#111;'> 135B </span>","children":null,"spread":false}],"spread":false},{"title":"77","children":[{"title":"d5e17979ecf1921c5659090e42e929219c8da1 <span style='color:#111;'> 784B </span>","children":null,"spread":false}],"spread":false},{"title":"49","children":[{"title":"14d6f90950403096dca09c0a7c9c11176d607a <span style='color:#111;'> 97B </span>","children":null,"spread":false}],"spread":false},{"title":"17","children":[{"title":"3d0acf61f9dcfb470a9b87051400efd22caf36 <span style='color:#111;'> 52B </span>","children":null,"spread":false}],"spread":false}],"spread":false},{"title":"HEAD <span style='color:#111;'> 23B </span>","children":null,"spread":false},{"title":"config <span style='color:#111;'> 137B </span>","children":null,"spread":false},{"title":"refs","children":[{"title":"heads","children":null,"spread":false},{"title":"tags","children":null,"spread":false}],"spread":true},{"title":"branches","children":null,"spread":false},{"title":"hooks","children":[{"title":"pre-applypatch.sample <span style='color:#111;'> 398B </span>","children":null,"spread":false},{"title":"pre-push.sample <span style='color:#111;'> 1.32KB </span>","children":null,"spread":false},{"title":"commit-msg.sample <span style='color:#111;'> 896B </span>","children":null,"spread":false},{"title":"pre-commit.sample <span style='color:#111;'> 1.60KB </span>","children":null,"spread":false},{"title":"applypatch-msg.sample <span style='color:#111;'> 452B </span>","children":null,"spread":false},{"title":"prepare-commit-msg.sample <span style='color:#111;'> 1.21KB </span>","children":null,"spread":false},{"title":"update.sample <span style='color:#111;'> 3.53KB </span>","children":null,"spread":false},{"title":"post-update.sample <span style='color:#111;'> 189B </span>","children":null,"spread":false},{"title":"pre-rebase.sample <span style='color:#111;'> 4.83KB </span>","children":null,"spread":false}],"spread":true},{"title":"description <span style='color:#111;'> 73B </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}]

评论信息

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明