- 博客(8)
- 资源 (5)
- 收藏
- 关注
原创 开始学习linux
从可爱的炫酷的windows IDE到Vim。。。。。。iconv命令详解功能] 对于给定文件把它的内容从一种编码转换成另一种编码。 [描述] -f encoding :把字符从encoding编码开始转换。 -t encoding :把字符转换到encoding编码。 -l :列出已知的编码字符集合 -o file :指定输出文件 -c
2017-08-09 23:03:54
233
原创 [leetcode]382. Linked List Random Node
382. Linked List Random NodeGiven a singly linked list, return a random node's value from the linked list. Each node must have the same probability of being chosen.Follow up:What if the li
2016-10-22 15:38:46
293
原创 [leetcode]421. Maximum XOR of Two Numbers in an Array
421. Maximum XOR of Two Numbers in an ArrayGiven a non-empty array of numbers, a0, a1, a2, … , an-1, where 0 ≤ ai < 231.Find the maximum result of ai XOR aj, where 0 ≤ i, j n.Cou
2016-10-20 16:08:19
2870
原创 [leetcode]404. Sum of Left Leaves
404. Sum of Left LeavesFind the sum of all left leaves in a given binary tree.Example: 3 / \ 9 20 / \ 15 7There are two left leaves in the binary tree, with values 9 and
2016-10-20 11:20:45
385
转载 C++中的静态数据成员的作用与好处
静态成员如果有n个同类的对象,那么每一个对象都分别有自己的数据成员,不同对象的数据成员各自有值,互不相干。但是有时人们希望有某一个或几个数据成员为所有对象所共有。这样可以实现数据共享。在前面介绍过全局变量能够实现数据共享。如果在一个程序文件中有多个函数,在每一个函数中都可以改变全局变量的值,全局变量的值为各函数共享。但是用全局变量的安全性得不到保证,由于在各处都可以自由地修改全局变量的值,
2012-09-04 23:30:37
1306
原创 C++ char类型
C++primer中: 和其他整型不同,char 有三种不同的类型:plain char 、unsigned char 和signed char。虽然 char 有三种不同的类型,但只有两种表示方式。可以使用unsigned char 或 signed char 表示 char 类型。使用哪种 char 表示方式由编译器而定。 整型 in
2012-08-20 22:18:22
819
转载 计算机中的magic number
计算机中magic number 在计算机中可译为"幻数",或者"魔数",或者直接称其为magic number.中国台湾的叫法是魔术数字.它可以用来标记文件或者协议的格式.很多文件都有magic标志来表明该文件的格式. 例如win32可执行程序的开头标记一般为[MZ],这是一种源于DOS时代的格式. rar压缩档文件的开头有[Rar]三个字符,zip文档开头为[PK] ("pack")可以用
2012-08-12 18:13:08
2325
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人