- 博客(9)
- 资源 (2)
- 收藏
- 关注
原创 Radix sort
The whole idea is that we’re doing a digitby digit sort. We are going to do it from least significant to mostsignificant. Let's think of here are n numbers and the numbers are binary, each int...
2018-05-15 17:31:36 629
原创 Counting sort
You can comprehend this problem from two different points of view. Case 1: For an element x in an array, to check how many elements is less than x, after we got that message, we can p...
2018-05-15 15:58:28 295
原创 heapsort
Heapsort is not a stable sort algorithm. In order to learn this algorithm, you need to know some concepts first.Actually, the heap is binary tree, a parent node has two children nodes, the parent is ...
2018-05-09 22:14:25 244
原创 quick sort and randomized quick sort
The idea of classic quick sort is to divided the original array to two parts, and the when you doing the partition, you should make sure the element in left subarray always less than a pivot, and ...
2018-05-04 12:51:58 202
原创 find largest sub array
There are two ways to solve the problem of largest sub array:1: divide-and-conquer method2: linear search methodNow let me introduce them one by one.1: divide-and-conquer methodThe core idea of it is ...
2018-04-17 09:58:40 191
原创 merge-sort
Divide and conquer is the core idea of merge sort. You can recursively divide the original array into two sub-arrays, until each sub-array only has one element. At the last, it looks like a tree, the ...
2018-03-28 14:51:52 434
原创 selection-sort
The core idea of the selection sort is to choose the minimum/maximum element from the remaining elements in the array, and then put it to the end of the elements that you have already sorted.The detai...
2018-03-27 11:13:26 134
原创 insertion-sort
The core idea of the insertion sort is to place an element in the appropriate location in the array.The detail steps of this algorithm are as follows:1. Choose an element from left to right, and ...
2018-03-27 10:36:56 575
原创 Welcomes like-minded people
As an old programmer, I am conscious of that I need to learn in depth, so I reorganized my blog. I’m going to learning some original English books. I would like to write an article after study per tim...
2018-03-22 16:24:40 255 3
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人