0 votes 0 votes In a 3-array tree if internal nodes have exactly 3 children,the number of leaf nodes will be __ ? Does it vary for binary tree? What do you mean by internal nodes? Non root node and leaf node? DS binary-tree tree graph-theory algorithms data-structures + – sripo asked Dec 25, 2018 recategorized Jul 6, 2022 by Lakshman Bhaiya sripo 4.7k views answer comment Share Follow See all 6 Comments See all 6 6 Comments reply Shobhit Joshi commented Dec 25, 2018 reply Follow Share if total node is $N$ $n_l = \frac{2N+1}{3}$ ? 0 votes 0 votes sripo commented Dec 25, 2018 reply Follow Share I dont know the answer. 0 votes 0 votes Lakshman Bhaiya commented Dec 25, 2018 reply Follow Share see this 0 votes 0 votes sripo commented Dec 25, 2018 reply Follow Share Is root node counted as internal node? Btw what software did you use to draw the graph? Paint? 0 votes 0 votes Shobhit Joshi commented Dec 25, 2018 reply Follow Share @sripo root node is also an internal node unless it is the only node in the tree 0 votes 0 votes Lakshman Bhaiya commented Dec 25, 2018 reply Follow Share Yes i used paint. 0 votes 0 votes Please log in or register to add a comment.
1 votes 1 votes Formula for Leaf Nodes= I(N-1)+1 I---internal nodes N---n array tree i.e 3 Hence, Leaf Nodes= 3(3-1)+1 = 3×2+1 = 7 nodes Annu mor answered Dec 3, 2019 Annu mor comment Share Follow See 1 comment See all 1 1 comment reply Vishnu__ commented Dec 1, 2022 reply Follow Share how did u take 3internal nodes? 0 votes 0 votes Please log in or register to add a comment.
0 votes 0 votes 1. Internal node means non leaf node. we have for n ary tree no of leaf node=X(n-1) +1 [By hand shake degree theorem] where X =no of internal node So for your question n=3 =>no of leaf node=2*X + 1 it will be [X(2-1) +1 =X+1] for binary tree n=2. Abhisek Tiwari 4 answered Dec 25, 2018 Abhisek Tiwari 4 comment Share Follow See all 0 reply Please log in or register to add a comment.