原创 LeetCode OJ - Recover Binary Search Tree

Two elements of a binary search tree (BST) are swapped by mistake. Recover the tree without changing its structure. N

原创 LeetCode OJ - Word Ladder II

Given two words (start and end), and a dictionary, find all shortest transformation sequence(s) from start to end, s

原创 LeetCode OJ - Edit Distance

Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation

原创 LeetCode OJ - Flatten Binary Tree to Linked List

Given a binary tree, flatten it to a linked list in-place. For example, Given 1 / \ 2 5

原创 LeetCode OJ - Sqrt(x)

Implement int sqrt(int x). Compute and return the square root of x. 分析:二分法和牛頓迭代法 牛頓迭代方程:x2 = x1 / 2 + x / x1 cl

原创 《Linux驅動基礎篇》- Linux內存管理深入篇

        基礎篇 《Linux驅動基礎篇》- Linux內存管理篇  從應用的角度來介紹了Linux內存管理,內容包括:物理頁的描述、分區、struct page的分配與釋放、kmalloc與vmalloc、頻繁使用的對象如何管理

原创 LeetCode OJ - Sort Colors

Given an array with n objects colored red, white or blue, sort them so that objects of the same color are adjacent, wi

原创 LeetCode OJ - Maximal Rectangle

Given a 2D binary matrix filled with 0's and 1's, find the largest rectangle containing all ones and return its area. 分

原创 LeetCode OJ - Distinct Subsequences

Given a string S and a string T, count the number of distinct subsequences of T in S. A subsequence of a string is a

原创 LeetCode OJ - Same Tree

Given two binary trees, write a function to check if they are equal or not. Two binary trees are considered equal if

原创 LeetCode OJ - Symmetric Tree

Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center). For example, this bin

原创 LeetCode OJ - Word Ladder

Given two words (start and end), and a dictionary, find the length of shortest transformation sequence from start to e

原创 LeetCode OJ - Search in Rotated Sorted Array II

Follow up for "Search in Rotated Sorted Array": What if duplicates are allowed? Would this affect the run-time comple

原创 讀《我的互聯網方法論》

        最近花了幾天時間《我的互聯網方法論》第一遍讀完,書真的很不錯,通俗易懂不裝逼,讓人能夠思考互聯網是什麼。書的內容包括:1.互聯網時代 2.用戶至上 3.顛覆式創新 4.免費時代 5.體驗爲王。         書讀完了,那

原创 LeetCode OJ - Text Justification

Text Justification   Given an array of words and a length L, format the text such that each line has exactly L c