Consider the string abbccddeee. Each letter in the...
Guiding State PSC aspirants since 2016 50,000+ students · 1,000+ final selections Exam Calendar Results Call 9116926003
pscnotes
Pick your state
GPSC Prelims previous year questions

Consider the string abbccddeee. Each letter in the string must be assigned a binary code satisfying the following properties: For any two letters, the code assigned to one letter must not be a prefix of the code assigned to the other letter. For any two letters of the same frequency, the letter which occurs earlier in the dictionary order is assigned a code whose length is at most the length of the code assigned to the other letter. Among the set of all binary code assignments which satisfy the above two properties, what is the minimum length of the encoded string?

Asked in GPSC Assistant Director (IT), Class-1 2025

  1. 21
  2. 23
  3. 25
  4. 30

Answer under review: our editors are checking this question. Try the other GPSC Prelims previous year questions questions meanwhile.

More GPSC Prelims previous year questions questions

All 77,252 GPSC Prelims previous year questions questions →