10 2017 档案

摘要:// list.cpp : 定义控制台应用程序的入口点。// #include "stdafx.h"#include <list>#include <iostream>using namespace std;//using std::list; int _tmain(int argc, _TCHAR 阅读全文
posted @ 2017-10-27 12:11 阿蓉 阅读(161) 评论(0) 推荐(0)
摘要:#include <iostream>#include <vector>using namespace std;int main(){ /* vector线性容器 类似于数组 */ vector<int> vecInt; //不带参数 vecInt.push_back(1);//往后面加一个 vec 阅读全文
posted @ 2017-10-27 12:10 阿蓉 阅读(191) 评论(0) 推荐(0)
摘要:// deque.cpp : 定义控制台应用程序的入口点。// deque容器//称双端队列//支持随机访问,同时能和list一样在头部和尾部插入和删除数据/* deque()声明一个空deque deque(n)声明一个0到n-1个元素的deque deque(n,val)声明一个n个值为val的 阅读全文
posted @ 2017-10-27 12:09 阿蓉 阅读(227) 评论(0) 推荐(0)
摘要:#include "stdafx.h"#include<string>#include<list>#include<iostream>using namespace std;int _tmain(int argc, _TCHAR* argv[]){ string str("abc"); str[0] 阅读全文
posted @ 2017-10-25 10:41 阿蓉 阅读(139) 评论(0) 推荐(0)