C++ 面试知识点
mspeterwang
这个作者很懒,什么都没留下…
展开
-
一. C&C++ 基础二
C 语言和C++ 的区别 C语言是面向结构的,而c++ 是面向对象的 。 结构体,联合体,以及类的区别 联合体: union A{ int i; char b; }; 使用不同类型的变量共享一段内存 。 结构体: 把不同的的数据类型组成新的结构 。 struct B{ int a ; //4 字节 32位系统 char b;原创 2017-04-26 15:25:35 · 143 阅读 · 0 评论 -
一. C&C++ 基础一
1.指针相关Sample: a. int *a[10] //指针数组 b. int (*a)[10] //数组指针(数组里面存放的是指针) c. int (*a)(int) //指针函数 d. int (*a[10])(int) //函数指针数组(数组里存放的是函数指针) e. int *a,int **a //指向a 的原创 2017-04-26 16:57:59 · 172 阅读 · 0 评论 -
LeetCode: 4 Sum
Given an array S of n integers, are there elements a, b, c, and d in S such that a + b + c + d = target? Find all unique quadruplets in the array which gives the sum of target.Note: The solution set mu原创 2017-06-21 17:23:23 · 158 阅读 · 0 评论