CSD203_-_D01_3498.webp
Lan Anh1

CSD203_-_D01_3498.webp

  • Media owner Lan Anh1
  • Ngày thêm
Bài viết gốc: Chủ đề 'CSD203 - D01'
Kizspy.me
1
Class OrderQueue: is a queue structure (implemented as a linked list), where the nodes
contain Item objects. This Queue is used to manage all the items with FIFO (First In - First
Out) rule.
Class ItemTree: is a Binary Search Tree structure, where the nodes also contain Item
objects. This Tree's role is to store, search and sort data (alphabetically) in ascending order
(inOrder traversal)
Class ComputerStore: is the main class of the program, containing an OrderQueue and an
ItemTree.
Students are required to carefully read the provided code segments to fully understand the
relationships between the classes and the functions within each class. The specific task of the test
is to execute the following requirements:
a. f1(): To complete the requirement f1, students need to fulfill these two specific tasks:
implement the function enqueue() in the OrderQueue structure and the function insert()
in the Item Tree structure. The expected input/output used to test your code are as follows:
INPUT:
(Create a computer store with OrderQueue and ItemTree containing 7
7
nodes)
data.txt
(This file stores data)
1
OUTPUT:
Order Queue:
(Choose the question f1())
A, Computer
E, Tablet
Zoom
B, Keyboard
G Phone
+ 100%
Close
Chưa có bình luận nào.

Thông tin

Category
CSD203
Thêm bởi
Lan Anh1
Ngày thêm
Lượt xem
1,608
Lượt bình luận
0
Rating
0.00 star(s) 0 đánh giá

Share this media

Back
Bên trên Bottom