- 博客(9)
- 资源 (4)
- 收藏
- 关注
原创 LeetCode --- Plus One
Plus OneGiven a non-negative number represented as an array of digits, plus one to the number.The digits are stored such that the most significant digit is at the head of the list.My Submitted Codeclas
2015-06-07 21:45:22 474
原创 LeetCode --- Climbing Stairs
Climbing Stairs You are climbing a stair case. It takes n steps to reach to the top. Each time you can either climb 1 or 2 steps. In how many distinct ways can you climb to the top?My Submitted
2015-06-07 21:42:27 505
原创 LeetCode --- Add Binary
Add Binary Given two binary strings, return their sum (also a binary string). For example, a = “11” b = “1” Return “100”.My Submitted Codeclass Solution {public: string addBinary(
2015-06-07 21:38:32 337
原创 LeetCode --- Maximum Subarray
Maximum Subarray Find the contiguous subarray within an array (containing at least one number) which has the largest sum. For example, given the array [−2,1,−3,4,−1,2,1,−5,4], the contiguous
2015-06-07 21:26:57 419
原创 LeetCode --- Combination Sum
Combination Sum Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where the candidate numbers sums to T. The same repeated number may be chosen from
2015-06-07 21:18:23 481
原创 SSDB --- zset实现
zsetzset是一种很有用的数据结构,你可能听说过set,但什么是zset呢?zset就是sorted_set(排序集),STL里有set,底层是用红黑树实现的,并没有提供sorted_set的实现,要实现一个zset并不难,比如SSDB的作者就用map和set实现了一个简单的zset。代码在ssdb/src/util/sorted_set.h sorted_set.cpp中。 sorted_s
2015-06-05 14:02:24 2589
原创 SSDB --- queue实现
SSDB介绍SSDB是一款nosql数据库,使用leveldb作为存储引擎,支持众多的数据结构,如 queue、zset和hash,宣称可用来替代redis,看来性能不可小觑。其作者是位国人,曾在360游戏部门任职过。SSDB被很多知名公司使用,代码质量不错。 http://ssdb.io/zh_cn/,代码托管在github。queue的实现leveldb本身是k/v数据库,如何在单纯的k/v上
2015-06-01 22:26:33 2764
Boost graph library User guide.pdf
2015-05-29
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人