
LeetCode OJ
qmsggg
ubuntu爱好者
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
Single Number
Given an array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a linear runtime complexity. Could you implement it without using ext原创 2014-04-02 20:35:54 · 602 阅读 · 0 评论 -
不一样的Sqrt(x)
Implement int sqrt(int x). Compute and return the square root of x. 这个题目我做了很长一段时间才通过,原因有很多,但是最头痛的是超时和越界; 最后看了别人的代码才知道用二分,,,, 要用unsigned long long,不然会越界; class Solution { public: int原创 2014-04-02 21:47:20 · 838 阅读 · 0 评论