4 votes 4 votes Which of the following frequencies for A,B,C and D can generate the following Huffman tree? (Select all that apply.)$p_A=0.4, p_B=0.3, p_C=0.2, p_D=0.1$$p_A=0.35, p_B=0.25, p_C=0.2, p_D=0.2$$p_A=0.25, p_B=0.25, p_C=0.25, p_D=0.25$$p_A=0.2, p_B=0.35, p_C=0.2, p_D=0.25$ Algorithms goclasses2024-mockgate-14 algorithms huffman-code multiple-selects 1-mark + – GO Classes asked Feb 5 • edited Feb 5 by Lakshman Bhaiya GO Classes 576 views answer comment Share Follow See 1 comment See all 1 1 comment reply ash_khola commented Feb 7 reply Follow Share I think only C is right option. 0 votes 0 votes Please log in or register to add a comment.
2 votes 2 votes how can B be answer if B needs to be pulled out first from priority queue.... other symmetry of A and B would lead to 2 different structure of binary tree and one of them would not match with given structure thecoderyabham answered Feb 6 thecoderyabham comment Share Follow See all 2 Comments See all 2 2 Comments reply Sachin Mittal 1 commented Feb 8 reply Follow Share I did not get it. Can you please explain more? Question Source: https://inst.eecs.berkeley.edu/~ee126/sp23/exam/mt2/sp19_sol.pdf 0 votes 0 votes thecoderyabham commented Feb 8 reply Follow Share Sir option B me A ki value 0.35 hai and B ki I value 0.25 to B left me aayega na A ke sath to given questions se match hi nahi hoyega phir 0 votes 0 votes Please log in or register to add a comment.