- 博客(8)
- 资源 (3)
- 收藏
- 关注
转载 C++:STL标准入门汇总
C++:STL标准入门汇总学无止境!!!第一部分:(参考百度百科) 一、STL简介STL(Standard Template Library,标准模板库)是惠普实验室开发的一系列软件的统称。它是由Alexander Stepanov、Meng Lee和David R Musser在惠普实验室工作时所开发出来的。现在虽说它主要出现在C++中,但在被
2017-02-24 15:39:03
245
转载 STL--迭代器(iterator)使用详解
指针与数组指针与其它数据结构呢?比如说链表?存储空间是非连续的。不能通过对指向这种数据结构的指针做累加来遍历。能不能提供一个行为类似指针的类,来对非数组的数据结构进行遍历呢?这样我们就能够以同样的方式来遍历所有数据结构(容器)。迭代器(Iterator)是指针(pointer)的泛化,它允许程序员以相同的方式处理不同的数据结构(容器)。STL中有五种类型的迭代器,它们分
2017-02-15 15:22:39
570
转载 c++ vector(向量)使用方法详解
vector 是向量类型,它可以容纳许多类型的数据,如若干个整数,所以称其为容器。vector 是C++ STL的一个重要成员,使用它时需要包含头文件:复制代码代码如下:#include;一、vector 的初始化:可以有五种方式,举例说明如下:(1) vector a(10); //定义了10个整型元素的向量(尖括号中为元素类型名,它可以是任何
2017-02-15 15:02:56
366
原创 [ns3] all warnings being treated as errors
本科做毕业设计的时候,用到了ns3做为仿真平台,而之所以使用ns3,是因为ns3中包含了多路径并发传输,这一模块在ns2中是没有的。但在运行程序时,出现了一个问题,就是编译代码时发生“all warnings being treated as errors”解决这个问题的办法其实挺简单的首先进入ns3的安装目录,之后进入“ns-allinone-3.14.1/ns-3.14.1/waf
2016-12-30 15:47:07
730
1
原创 [LeetCode] Longest Substring Without Repeating Characters
题目:Given a string, find the length of the longest substring without repeating characters.Examples:Given "abcabcbb", the answer is "abc", which the length is 3.Given "bbbbb", the an
2016-10-30 20:08:42
194
原创 [LeetCode] Add Two Numbers
题目:You are given two linked lists representing two non-negative numbers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it
2016-10-30 15:26:01
203
原创 [LeetCode] Two Sum
题目:Given an array of integers, return indices of the two numbers such that they add up to a specific target.You may assume that each input would have exactly one solution.Example:Given
2016-10-30 12:43:10
211
1
原创 第一篇博文,开始记录刷代码的过程
研究生生涯太忙,不过代码还是需要刷一刷,在刷的过程中,希望能够有个记录的平台,因此开始博客,记录自己刷题过程,方便回来查看,也希望能够得到高人的指点,也希望能够给其他人一些启示
2016-10-30 12:41:20
964
浙江大学PAT所有basic level答案
2016-10-30
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人