Lecture Data Structures: Lesson 36
20
lượt xem 2
download
lượt xem 2
download
Download
Vui lòng tải xuống để xem tài liệu đầy đủ
Lecture Data Structures: Lesson 36 provide students with knowledge about union by size; maintain sizes (number of nodes) of all trees, and during union; make smaller tree the subtree of the larger one; implementation: for each root node i, instead of setting parent[i] to -1, set it to -k if tree rooted at i has k nodes;...
Chủ đề:
Bình luận(0) Đăng nhập để gửi bình luận!
CÓ THỂ BẠN MUỐN DOWNLOAD