GATE CS 2007 · Asymptotic Analysis & Recurrences

MCQ · 1 mark · Problem PROG-DIVC-0136

Suppose the letters a, b, c, d, e, f have probabilities 1/2, 1/4, 1/8, 1/16, 1/32, 1/32 respectively. Which of the following is the Huffman code for the letter a, b, c, d, e, f?
  1. A
    0, 10, 110, 1110, 11110, 11111
  2. B
    11, 10, 011, 010, 001, 000
  3. C
    11, 10, 01, 001, 0001, 0000
  4. D
    110, 100, 010, 000, 001, 111

Solve it on GATE DA practice →More Searching & Sorting Algorithms problems

Show the worked solutionOfficial GATE Answer Key: Option A.See full step-by-step discussion on GateOverflow: https://gateoverflow.in/1271/gate2007-76

GATE DA practice: past exam problems by chapter, with worked solutions · gatedaprep.com