Skip to Main Content
Data Structures Using C, 2nd Edition by Pearson
book

Data Structures Using C, 2nd Edition by Pearson

by A. K. Sharma
May 2024
Intermediate to advanced content levelIntermediate to advanced
521 pages
14h 12m
English
Pearson India
Content preview from Data Structures Using C, 2nd Edition by Pearson
360 Data Structures Using C
The codes assigned to various leaf nodes are listed in the table given below:
Character Frequency Code Character Frequency Code
Б (space) 18 00 l 1 1101000
o 9 010 f 1 1101000
a 4 0110 i 2 110101
w 3 01110 . 2 110110
g 3 01111 , 2 110111
e 11 100 y 4 11100
n 7 1010 u 4 11101
r 7 1011 h 8 1111
t 7 1100
As expected, the most frequently occurring character called space (Б) has got the shortest code i.e.
‘00’. Similarly, the character ‘e’ has been assigned a shorter code i.e. 100. Obviously, the least frequently
occurring characters like l & f have been assigned the longest codes 1101000 and 1101001 respectively.
Let us now com
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Data Structures Using C

Data Structures Using C

Samir Kumar Bandyopadhyay, Kashi Nath Dey
Intermediate C Programming, 2nd Edition

Intermediate C Programming, 2nd Edition

Yung-Hsiang Lu, George K. Thiruvathukal

Publisher Resources

ISBN: 9781299831582