Encoding Trees 1

Use the encoding described in the tree below to encode "CAB".

110100 011110 001111 100100

This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try refreshing the page, (b) enabling javascript if it is disabled on your browser and, finally, (c) loading the non-javascript version of this page . We're sorry about the hassle.

3 solutions

Karleigh Moore
May 10, 2016

To figure out the encoding of each letter, trace through the tree and the path you take to the letter will be its encoding. To reach "A", we need to go down the "1" path at the first fork, and then the next "1" path at the next. Thus, the encoding for "A" is "11". We can do this process for the other letters.

The table below shows the encoding for each letter.

A 11
B 10
C 01
D 00

To encode "CAB" we take the encoding for C (01), concatenate that with the encoding for A (11), and then concatenate that with the encoding for B(00) so we get 011100 for CAB.

The other choices are:

100100 BCD
001111 DAA
110100 ACD

Isn't B (10) not 00?

kevin wang - 3 years, 1 month ago

Log in to reply

that's what I see too

Hosna eltaras - 3 years, 1 month ago

yes its 10 only

Shubham Kumar - 4 months, 4 weeks ago

B is 10 for sure

emre birdal - 2 years, 5 months ago

this is wrong

Coder Coderi - 2 years, 2 months ago

great learning!

onyinye ekwueme - 2 years, 1 month ago

This is wrong, B is 10 so CAB should be 01 11 10

Alvin Zhao - 11 months, 4 weeks ago

Log in to reply

Yes, you are right

Ahmed Atef - 3 months, 1 week ago

It makes me think like in order to discourage us you are going to say wrong for whatever choice we are going to make... B is sure

Abir Sohan - 7 months, 2 weeks ago

this is wrong its 011110 not 011100 (please edit your explanation. I'm confused )

Ethan SHEN - 6 months, 3 weeks ago

This is wrong u should edit ur explanation

Star Gaze - 6 months, 2 weeks ago
Star Gaze
Dec 1, 2020

01=C 11=A 10=B

Therefore, 01-11-10 or 011110 = CAB

now that is correct

Pola Wheeler - 4 weeks, 1 day ago
Ethan Shen
Nov 24, 2020

Actually you only have to work out the first 2 digits: C means 01, and there is only one answer that starts with 01. Really, it's that simple.

I know man!

Star Gaze - 6 months, 2 weeks ago

stupid neek this is honestly not helpful

josh edwards - 1 month, 3 weeks ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...