(C++) You are to create a binary tree that contains information
about pets. A pet struct has already been defined:
struct pet
{ string name;
string species;
int weight;
int number_of_legs; };
a: Define a class to represent a binary tree of pointers to
pets. Give it a constructor that creates an empty tree.
b: Define a method that adds a new pet to the tree. Pets are to
be stored in alphabetical order based on their names.
c: define a method that prints the name, species, and weight of
every pet in the tree, in alphabetical order.
(C++) You are to create a binary tree that contains information about pets. A pet struct has already been defined: struc
-
answerhappygod
- Site Admin
- Posts: 899604
- Joined: Mon Aug 02, 2021 8:13 am
(C++) You are to create a binary tree that contains information about pets. A pet struct has already been defined: struc
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!