Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit bbf9e2d

Browse files
refaactor 107
1 parent 8ddaacf commit bbf9e2d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

‎src/main/java/com/fishercoder/solutions/_107.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
public class _107 {
1212
public static class Solution1 {
13-
public List<List<Integer>> levelOrder(TreeNode root) {
13+
public List<List<Integer>> levelOrderBottom(TreeNode root) {
1414
List<List<Integer>> result = new ArrayList();
1515
if (root == null) {
1616
return result;

‎src/test/java/com/fishercoder/_107Test.java‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ public static void setup() {
2222
public void test1() {
2323
root = TreeUtils.constructBinaryTree(Arrays.asList(3, 9, 20, null, null, 15, 7));
2424
TreeUtils.printBinaryTree(root);
25-
CommonUtils.printListList(solution1.levelOrder(root));
25+
CommonUtils.printListList(solution1.levelOrderBottom(root));
2626
}
2727

2828
}

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /