14 Feb 2017
## tl;dr

This post shows how to use Electron as the GUI component of Python applications. (Updated version of one of my previous posts.) The frontend and backend communicate with each other using `zerorpc`

. The complete code is on GitHub repo.

...(Read more)

11 Jan 2017
topological sorting can be solved using DFS and BFS in asymptotical time complexity $O(V + E)$.

...(Read more)

22 Dec 2016
## tl;dr

Remember the core idea in React: `UI = func(const props, state)`

.

...(Read more)

21 Dec 2016
## tl;dr

I choose to use `create-react-app`

, then use ES2016 standard to write `react`

to build the UI and use `redux`

to manage the data, and write `flexbox`

to manage layouts in CSS, if I am going to start a completely new general-purposes front end project in early 2017.

...(Read more)

11 Dec 2016
## tl;dr

This post discusses the $O(n^2)$, $O(n log(n))$ complexity methods to find the length of longest increasing subsequence (LIS), and the way to recover the subsequence.

...(Read more)

03 Aug 2016
小周醒了过来。

...(Read more)

02 Jul 2016
### introduction

Edit Distance is a famous algorithm problem solved by dynamic programming. I heard it for multiple times, until now I understand the solution after having an algorithm class.

...(Read more)

17 Jun 2016
Hadley’s ggplot2 book is a useful resource about learning his `ggplot2`

package. He generously provides the online version for us to read. But how to compile and get the (personal) pdf version from the repo? I figure it out and note down here. I am working on Windows 10.

...(Read more)

01 Jun 2016
Heapsort is one of the algorithms for sorting, with average time complexity $O(n log(n))$ and worst $O(n log(n))$, and space complexity $O(1)$. I think it’s kind of interesting, so I write down the Java implementation here. Previously I was familar with the top-down (`siftUp()`

) method, but in this post I write down the buttom-up (`siftDown()`

) way, based on Wikipedia.

...(Read more)

25 May 2016
Quicksort is a usual algorithm for sorting, with average time complexity $O(n log(n))$ and worst $O(n^2)$, and (stack depth) space complexity $O(log(n))$. As an exercise, I wrote down the quicksort for array and linked list in Java here.

...(Read more)