CSD201_-_T1_-_SU_2024_2172.webp
T

CSD201_-_T1_-_SU_2024_2172.webp

The class Phone with 3 data members: id, weight and price is given and you do not need to edit it. In this s, id must be unique (there is no duplicated id in the list), weight>0, and price>0. The MyList class is a linked list of Phone objects. The following methods should be completed:
void addLast(String xld, int xWeight, int xPrice).void f1() - Do not edit this method. Your task is to complete the addLast(...) method above only.The expected output in the file f1.txt should be the following:(H,6,7) (C,4,5) (Y,5,8)
1
void f2() -There is a given Phone objects (named v) in this function. Suppose the list contains at least 3 elements. Write statements to insert v to the list such that v will be the 3rd node after insertion. The expected output in the file f2.txt should be the following:
Zoom
100%
Close
Chưa có bình luận nào.

Thông tin

Category
CSD201
Thêm bởi
thanhhoa88
Ngày thêm
Lượt xem
2,312
Lượt bình luận
0
Rating
0.00 star(s) 0 đánh giá

Image metadata

Filename
CSD201_-_T1_-_SU_2024_2172.webp
File size
130.6 KB
Dimensions
916px x 472px

Share this media

Back
Bên trên Bottom