### Blogroll

### Topics

- Apartment rental and roommate finding
- Array and linked list
- Backtrack
- Binary search
- Bit operation
- C++
- Complexity
- Divide and Conquer
- Dynamic programming
- File operation
- Geometry
- Graph
- Greedy algorithm
- Hashtable and Map
- Heap
- JAVA
- Large scale data
- Number trick
- Object orientated design
- Probability
- Recursive
- Stack and Queue
- String
- Threads and locks
- Tree
- Uncategorized

### Archives

# Monthly Archives: February 2013

## Longest Consecutive Sequence

Given an unsorted array of integers, find the length of the longest consecutive elements sequence. For example, Given [100, 4, 200, 1, 3, 2], The longest consecutive elements sequence is [1, 2, 3, 4]. Return its length: 4. Your algorithm should run in … Continue reading

## Sum Root to Leaf Numbers

Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number. An example is the root-to-leaf path 1->2->3 which represents the number 123. Find the total sum of all root-to-leaf numbers. For example, 1 / \ 2 3 The root-to-leaf … Continue reading

Posted in Recursive, Tree
Leave a comment