开发者

what is the name of this data structure

   (10)
   /  \
 (9)  (8)
 开发者_如何学Go/  \ /  \
(7) (5) (4) 

x        x
/   and  \    == x=>y
y         y


It's a directed acyclic graph (DAG), which can define a (partial) ordering relation.


That looks like a max-heap, except that (5) should not be attached to two parents.

A max-heap is a tree-based data structure where x>=y if x is a parent of y. Since it is a tree, each child can only have one parent.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜