Question: For 1.1 Load data from file: Just create some random data Your second assignment in this block will be using binary search tree data structure
For 1.1 Load data from file: Just create some random data

Your second assignment in this block will be using binary search tree data structure for implementing a small Sale Management System (SMS) in Java language. SMS manages information about products, customers and product ordering items. These information are: About a product: pcode (string): the code of the product (this is the key of the tree and thus should be unique). pro_name (string): the name of the product. quantity (integer): the number of products with the same code in a shop at beginning of a day. (integer): the number of products with the same code, which are in the day. Condition: lessthanorequalto quantity. price (double): The price of the product. About a customer: code (string): the code of the customer (this should be unique for the customer). cus_name (string): the name of the customer. phone (string): The phone number of the customer (must contain digits only). About ordering: (string): the code of the product to be ordered. (string): the code of the customer. quantity (integer): the number of ordered products. You should use 1 binary search tree to store data for products and 2 linked lists, each one is used to store data for customers or ordering items. You should create the data structures from scratch, do not use structures available in java. On running, your program displays the menu as below: Products (8 marks) (using Binary Search Tree data structure, where is the key of the tree): Load data from file Input & insert data In-order traverse Breadth-first traverse In-order traverse to file Search by Delete by by copying Simply balancing Count number of products Your second assignment in this block will be using binary search tree data structure for implementing a small Sale Management System (SMS) in Java language. SMS manages information about products, customers and product ordering items. These information are: About a product: pcode (string): the code of the product (this is the key of the tree and thus should be unique). pro_name (string): the name of the product. quantity (integer): the number of products with the same code in a shop at beginning of a day. (integer): the number of products with the same code, which are in the day. Condition: lessthanorequalto quantity. price (double): The price of the product. About a customer: code (string): the code of the customer (this should be unique for the customer). cus_name (string): the name of the customer. phone (string): The phone number of the customer (must contain digits only). About ordering: (string): the code of the product to be ordered. (string): the code of the customer. quantity (integer): the number of ordered products. You should use 1 binary search tree to store data for products and 2 linked lists, each one is used to store data for customers or ordering items. You should create the data structures from scratch, do not use structures available in java. On running, your program displays the menu as below: Products (8 marks) (using Binary Search Tree data structure, where is the key of the tree): Load data from file Input & insert data In-order traverse Breadth-first traverse In-order traverse to file Search by Delete by by copying Simply balancing Count number of products
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
