Skip to content

Commit 59a7318

Browse files
committed
update category
1 parent 41591f6 commit 59a7318

15 files changed

+40
-33
lines changed

README.md

+39-32
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ Coding Questions
1515
- [ ] [Graph](#graph)
1616
- [ ] [Sortiing and Search](#sortsearch)
1717
- [ ] [Dynamic Programming](#dp)
18+
- [ ] [Other](#other)
1819
- [ ] [Special Topics](#st)
1920

2021
###[[]](#toc) <a name='stat'>Statement:</a>
@@ -25,9 +26,9 @@ difficult, and the special topics include some advanced ones.
2526

2627
Most code style follows [Google C++ Style Guide](http://google-styleguide.googlecode.com/svn/trunk/cppguide.xml).
2728

28-
Total Number (not including the problem in the special topics) of Problems: about 202 (142 done).
29+
Total Number (not including the problem in the special topics) of Problems: about 201 (142 done).
2930

30-
Although I try to execute every program, bugs may still exist because the test cases are not enough, welcome to find bugs.
31+
Although I try to execute every program, bugs may still exist because I didn't run enough tests, welcome to find bugs.
3132
The solution may not be optimal, welcome to give your better solution. You can send the corresponding pull request.
3233

3334
By default, the time complexity is the worst time and the space complexity doesn't include the stack space.
@@ -57,19 +58,34 @@ By default, the time complexity is the worst time and the space complexity doesn
5758
* Find independent parts in an array
5859
* Find the longest consecutive increasing subarray in a grid
5960
* [Calculate the rotation distance for a sorted rotated array](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Array/Rotatearraydistance.cpp)
60-
* [Build b[i] = a[0]a[1]…a[n-1]/a[i]](https://github.com/checkcheckzz/coding-problem/blob/master/problem/Build%20b%5Bi%5D.cpp)
61+
* [Build b[i] = a[0]a[1]…a[n-1]/a[i]](https://github.com/checkcheckzz/coding-problem/blob/master/problem/Array/Build%20b%5Bi%5D.cpp)
62+
* [Find elements in first array but not in second array](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Array/Find%20none%20duplicate%20elements%20in%20two%20arrays.cpp)
63+
* [Find the maximal item A[i], such that A[i]=A[x]+A[y] in an array](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Array/Find%20the%20max%20item%20A%5Bi%5D,%20such%20that%20A%5Bi%5D=A%5Bx%5D+A%5By%5D.cpp)
64+
* [Length of first subarray that sums to zero](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Array/Length%20of%20First%20continuous%20subarray%20that%20sums%20to%200.cpp)
65+
* [Stable 2 way partition](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Array/Stable%202%20way%20partition.cpp)
66+
* Water flow path
67+
* Form an ascending sequence by removing elements
68+
* Celebrity problem
69+
* Matrix Region Sum
70+
* Recover the queue
71+
* Find a rectangle with four corners 1
6172

6273
--
6374
####[[]](#toc) <a name='str'>String:</a>
6475

6576
* [Given a string, print out the chars with maximal number of consecutive counts](https://github.com/checkcheckzz/coding-problems/blob/master/problem/String/Chars%20with%20maximal%20number%20of%20consecutive%20counts.cpp)
6677
* [Generate parentheses with different types](https://github.com/checkcheckzz/coding-problems/blob/master/problem/String/GenerateParentheseswithdiffkinds.cpp)
67-
78+
* [Remove comments](https://github.com/checkcheckzz/coding-problems/blob/master/problem/String/Remove%20comments.cpp)
79+
* [String of digits, insert addition operator in between to make sum to be a value](https://github.com/checkcheckzz/coding-problems/blob/master/problem/String/Makesum.cpp)
80+
* [Name numbers](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Namenumbers.cpp)
6881

6982
--
7083
####[[]](#toc) <a name='list'>Linked List:</a>
7184

7285
* [List Level Sum](https://github.com/checkcheckzz/coding-problems/blob/master/problem/LinkedList/List%20level%20sum.cpp)
86+
* [Insert into a Cyclic Sorted List](https://github.com/checkcheckzz/coding-problems/blob/master/problem/LinkedList/Insert%20into%20a%20Cyclic%20Sorted%20List.cpp)
87+
* [Given linked list as a-x-b-y-c-z, output it as a-b-c-z-y-x](https://github.com/checkcheckzz/coding-problems/blob/master/problem/LinkedList/Reversealternatelist.cpp)
88+
* Flatten a list
7389

7490
--
7591
####[[]](#toc) <a name='heap'>Heap:</a>
@@ -97,54 +113,45 @@ By default, the time complexity is the worst time and the space complexity doesn
97113
--
98114
####[[]](#toc) <a name='graph'>Graph:</a>
99115

116+
* [Traversal a Grid](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Graph/Traversalgrid.cpp)
117+
* [How many carrots can the rabbit eat](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Graph/How%20many%20carrots%20can%20the%20rabbit%20eat.cpp)
118+
* [Number of closed rectangles in a matrix](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Graph/Numberclosedrectangles.cpp)
119+
* [Valid whether a graph exists](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Graph/Graph%20exists.cpp)
120+
* Calculate the distance from each empty room to nearest guard
121+
* [Graph Components](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Graph/Graphcomponents.cpp)
122+
100123
--
101124
####[[]](#toc) <a name='sortsearch'>Sorting and Search:</a>
102125

103126
* [Find the smallest missing number](https://github.com/checkcheckzz/coding-problems/blob/master/problem/SortSearch/Smallestmissingnumber.cpp)
104127
* Kth element in two sorted arrays
105128
* [Find the minimal number in a given left turned array](https://github.com/checkcheckzz/coding-problems/blob/master/problem/SortSearch/Minimalelementinleftsortedarray.cpp)
106129
* [Find first target in a sorted array with duplicates](https://github.com/checkcheckzz/coding-problems/blob/master/problem/SortSearch/Find%201st%20one%20in%20large%20duplicated%20sorted%20array.cpp)
130+
* Search a target in an array with unknown length
131+
* [Sorting](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Sorting.cpp)
107132

108133
--
109134
####[[]](#toc) <a name='dp'>Dynamic Programming:</a>
110135

111136
* [Max production subarray](https://github.com/checkcheckzz/coding-problems/blob/master/problem/DynamicProgramming/Max%20production%20subarray.cpp)
112137
* Jump the river
138+
* [Minimal subset sum](https://github.com/checkcheckzz/coding-problems/blob/master/problem/DynamicProgramming/Minimal%20subset%20sum.cpp)
113139

114140
--
115141

142+
####[[]](#toc) <a name='other'>Other:</a>
116143

117-
118-
119-
* [Find elements in first array but not in second array](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Find%20none%20duplicate%20elements%20in%20two%20arrays.cpp)
120-
* [Remove comments](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Remove%20comments.cpp)
121-
* [Find the maximal item A[i], such that A[i]=A[x]+A[y] in an array](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Find%20the%20max%20item%20A%5Bi%5D,%20such%20that%20A%5Bi%5D=A%5Bx%5D+A%5By%5D.cpp)
122144
* [Implement memmove and memcopy](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Implement%20memmove%20and%20memcopy.cpp)
123-
* [Insert into a Cyclic Sorted List](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Insert%20into%20a%20Cyclic%20Sorted%20List.cpp)
124-
* [Length of first subarray that sums to zero](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Length%20of%20First%20continuous%20subarray%20that%20sums%20to%200.cpp)
125-
* [Minimal subset sum](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Minimal%20subset%20sum.cpp)
126-
* [Stable 2 way partition](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Stable%202%20way%20partition.cpp)
145+
127146
* [Matrix Iterator](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Iterator%20for%20matrix.cpp)
128-
* Kth element in young tableau
129-
* [Given linked list as a-x-b-y-c-z, output it as a-b-c-z-y-x](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Reversealternatelist.cpp)
130-
* [String of digits, insert addition operator in between to make sum to be a value](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Makesum.cpp)
131-
* Water flow path
132-
* Form an ascending sequence by removing elements
133-
* Celebrity problem
134-
* Matrix Region Sum
135-
* Recover the queue
136-
* Flatten a list
137-
* Find a rectangle with four corners 1
138-
* Search a target in an array with unknown length
139-
* [Sorting](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Sorting.cpp)
140-
* [Name numbers](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Namenumbers.cpp)
147+
--
148+
149+
150+
141151
* Closest pair problem
142-
* [Traversal a Grid](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Traversalgrid.cpp)
143-
* [How many carrots can the rabbit eat](https://github.com/checkcheckzz/coding-problems/blob/master/problem/How%20many%20carrots%20can%20the%20rabbit%20eat.cpp)
144-
* [Number of closed rectangles in a matrix](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Numberclosedrectangles.cpp)
145-
* [Valid whether a graph exists](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Graph%20exists.cpp)
146-
* Calculate the distance from each empty room to nearest guard
147-
* [Graph Components](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Graphcomponents.cpp)
152+
153+
154+
148155
* Construct a xml tree
149156
* [Heapify a binary tree](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Heapify%20a%20binary%20tree.cpp)
150157
* [Immediate right neighbor of given node (parent links, no root) in binary tree](https://github.com/checkcheckzz/coding-problems/blob/master/problem/Immediate%20right%20neighbor.cpp)

problem/Minimal subset sum.cpp renamed to problem/DynamicProgramming/Minimal subset sum.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ output 1
1212

1313
/*
1414
15-
solution: dynamic programming.The problem transfers to partition the array to two parts such that their difference is as close as possible.
15+
solution: dynamic programming. The problem transfers to partition the array to two parts such that their difference is as close as possible.
1616
1717
part[i][j]:true if a subset of {arr[0], arr[1], ..arr[j-1]} has sum equal to i, otherwise false
1818
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)