Created
August 12, 2023 04:10
-
-
Save minsang-alt/6bccb1e27f6071d45bce9557d0ab1987 to your computer and use it in GitHub Desktop.
Node클래스
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package com.javaStudyTest.binaryTree; | |
public class Node { | |
private int value; | |
private Node left; | |
private Node right; | |
public Node(int value){ | |
this.value = value; | |
right = null; | |
left = null; | |
} | |
public int getValue() { | |
return value; | |
} | |
public Node getLeft() { | |
return left; | |
} | |
public Node getRight() { | |
return right; | |
} | |
public void setLeft(Node left) { | |
this.left = left; | |
} | |
public void setRight(Node right) { | |
this.right = right; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment