CSD201_-_1_-_FA_2023_-_FE_1030.webp
H

CSD201_-_1_-_FA_2023_-_FE_1030.webp

(Choose 1 answer)
Suppose we are considering a singly linked list and p is some node in the list which has both predecessor and successor nodes.
Select the most correct java code snippet that deletes the node p.
A. Node f= head;
while(f.next != null) f = f.next;f.next = p.next;
B. Node f= head;while(f != p) f = f.next;f.next = p.next;
C. Node f= head;while(f.next != p) f = f.next;f.next = p.next;
D. Node f = head;
while(f != null) f = f.next;f.next = p.next;


Exit 6

Thông tin

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

Image metadata

Filename
CSD201_-_1_-_FA_2023_-_FE_1030.webp
File size
54 KB
Dimensions
1542px x 690px

Share this media

Back
Bên trên Bottom