adding cs235
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
#include "node.h"
|
||||
|
||||
node::node(int data): data(data), height(0), right(NULL), left(NULL) {}
|
||||
|
||||
int node::getData() {
|
||||
return data;
|
||||
}
|
||||
|
||||
NodeInterface* node::getLeftChild() {
|
||||
return left;
|
||||
}
|
||||
|
||||
NodeInterface* node::getRightChild() {
|
||||
return right;
|
||||
}
|
||||
|
||||
int node::getHeight() {
|
||||
return height;
|
||||
}
|
||||
Reference in New Issue
Block a user