CSD201_-_SP_2025_-_FE_3621.webp
Kim Anh1

CSD201_-_SP_2025_-_FE_3621.webp

  • Media owner Kim Anh1
  • Ngày thêm
☑Kizspy.me
(Choose 1 answer)
☐ A
Suppose we are considering a binary search tree.
Select the most correct java code snippet
that search a node with value x.
A. Node search(int x)
{ Node p = root;
while(p.info != x && p!=null)
{if(x<p.info) p = p.left;
else p=p.right;
return(p);
}
}
B. Node search(int x)
{ Node p = root;
while(p.info != x)
{if(x<p.info) p p.left;
}
}
else p=p.right;
return(p);
C. Node search(int x)
{ Node p = root;
while(p!=null && p.info != x)
{if(x<p.info) p p.left;
else p=p.right;
FUO.sh
sh the exam.
}
return(p);
}

Thông tin

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

Share this media

Back
Bên trên Bottom