Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

#include #include #include #include BST . h / / * * * do not change the headers * * * / / you

#include
#include
#include
#include "BST.h"
//***do not change the headers***
// you solutions go here
// remember that you do not need to implement all of them
// follow the document to see which ones you need to implement
BST::BST(){
}
BST::~BST(){
}
std::shared_ptr BST::search(int target){
return nullptr;
}
std::shared_ptr BST::search(std::shared_ptr n, int target){
return nullptr;
}
std::shared_ptr BST::minimum(){
return nullptr;
}
std::shared_ptr BST::minimum(std::shared_ptr n){
return nullptr;
}
std::shared_ptr BST::maximum(){
return nullptr;
}
std::shared_ptr BST::maximum(std::shared_ptr n){
return nullptr;
}
void BST::insertValue(int val){
}
std::shared_ptr BST::insertValue(std::shared_ptr n, int val){
return nullptr;
}
void BST::deleteValue(int val){
}
std::shared_ptr BST::deleteValue(std::shared_ptr n, int val){
return nullptr;
}
bool BST::isBST(std::shared_ptr n){
return false;
}
bool BST::isBST(std::shared_ptr n, int low, int high){
return false;
}
void BST::preOrder(std::shared_ptr n, std::vector> &order){
}
void BST::inOrder(std::shared_ptr n, std::vector> &order){
}
void BST::postOrder(std::shared_ptr n, std::vector> &order){
}
Assignment Questions (95 pts)
Implement the insert method for binary search trees. Do not insert duplicate
values.
Implement the search method for binary search trees.
Implement isBST, a method for checking whether or not a tree is a binary
search tree.
Implement the pre-order traversal method for binary search trees.
How do I do this in C++?
image text in transcribed

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Nested Relations And Complex Objects In Databases Lncs 361

Authors: Serge Abiteboul ,Patrick C. Fischer ,Hans-Jorg Schek

1st Edition

3540511717, 978-3540511717

More Books

Students also viewed these Databases questions

Question

Presentations Approaches to Conveying Information

Answered: 1 week ago