Skip to content
Related Articles

Related Articles

UGC-NET | UGC NET CS 2017 Jan – III | Question 67
  • Last Updated : 01 Feb, 2019

From the given data below :
a b b a a b b a a b
which one of the following is not a word in the dictionary created by LZ-coding (the initial words are a, b)?
(A) a b
(B) b b
(C) b a
(D) b a a b


Answer: (B) (D)

Explanation: Input is : a b b a a b b a a b
According to L-Z coding:
The dictionary contains: a | b | ba | ab| baa (is already there)
baab and bb are not there
So, option B and D are correct.

Quiz of this Question

Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a student-friendly price and become industry ready.

My Personal Notes arrow_drop_up
Recommended Articles
Page :