Skip to content

Commit aaf09a1

Browse files
edit 113
1 parent 0e5f06b commit aaf09a1

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -442,6 +442,7 @@ Your ideas/fixes/algorithms are more than welcome!
442442
|116|[Populating Next Right Pointers in Each Node](https://leetcode.com/problems/populating-next-right-pointers-in-each-node/)|[Solution](../master/src/main/java/com/fishercoder/solutions/_116.java)| O(n)|O(1) | Medium| BFS
443443
|115|[Distinct Subsequences](https://leetcode.com/problems/distinct-subsequences/)|[Solution](../master/src/main/java/com/fishercoder/solutions/DistinctSubsequences.java)| O(m*n)|O(m*n) | Hard| DP
444444
|114|[Flatten Binary Tree to Linked List](https://leetcode.com/problems/flatten-binary-tree-to-linked-list/)|[Solution](../master/src/main/java/com/fishercoder/solutions/_114.java)| O(n)|O(h) | Medium| Tree
445+
|113|[Path Sum II](https://leetcode.com/problems/path-sum-ii/)|[Solution](../master/src/main/java/com/fishercoder/solutions/_113.java)| O(n)|O(h) | Medium| DFS
445446
|112|[Path Sum](https://leetcode.com/problems/path-sum/)|[Solution](../master/src/main/java/com/fishercoder/solutions/_112.java)| O(n)|O(1) | Easy| DFS
446447
|111|[Minimum Depth of Binary Tree](https://leetcode.com/problems/minimum-depth-of-binary-tree/)|[Solution](../master/src/main/java/com/fishercoder/solutions/MinimumDepthofBinaryTree.java)| O(n)|O(1)~O(h) | Easy| BFS, DFS
447448
|110|[Balanced Binary Tree](https://leetcode.com/problems/balanced-binary-tree/)|[Solution](../master/src/main/java/com/fishercoder/solutions/_110.java)| O(n)|O(1)~O(h) | Easy| DFS

src/main/java/com/fishercoder/solutions/PathSumII.java renamed to src/main/java/com/fishercoder/solutions/_113.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
[5,8,4,5]
2525
]
2626
*/
27-
public class PathSumII {
27+
public class _113 {
2828
//also, it's possible that a node's value could be negative, as long as the sum of root to leaf ends up to sum
2929
public List<List<Integer>> pathSum(TreeNode root, int sum) {
3030
List<List<Integer>> allPaths = new ArrayList();
@@ -54,7 +54,7 @@ private void dfs(TreeNode root, List<Integer> path, List<List<Integer>> allPaths
5454

5555

5656
public static void main(String...strings){
57-
PathSumII test = new PathSumII();
57+
_113 test = new _113();
5858
// TreeNode root = new TreeNode(1);
5959
// root.left = new TreeNode(2);
6060
// int sum = 1;

0 commit comments

Comments
 (0)