Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Qs 1. Write a function that generates a string considering the string MYIDISONETWOTHREETHREE Qs 2. Write a function that uses huffman coding to generate prefix

Qs 1. Write a function that generates a string considering the string MYIDISONETWOTHREETHREE

Qs 2. Write a function that uses huffman coding to generate prefix code of the letters in the string MYIDISONETWOTHREETHREE

For question 1 and 2 I am uploading a random picture which shows how the sequence of execution will look like.

image text in transcribed

(Instructions For question 1 and 2) This coding for question 1,2 should be done in c or c++ in codeblocks and both questions 1 and 2 should be in a single program.

2.Should not use any direct function which generates the huffman coding simply or reduce the coding part. It should be done manually that means don't use any function which is inbuilt that generates the huffman coding directly which reduces the coding part.

The functions in Question-1 and 2 will be in a single program and sequence of execution should look something like Figure 1. Step 1. Enter Student ID: 134436 Step 42. Generated String: MYIDISFOURFOURTHREESIX Step 3. Prefix Codes (Generated Using Huffman Coding): M: 1101 1100 I: 011 D: 1011 S: 0011 0010 O: 0001 0000 R: 010 T: 1010 1001 E: 111 X: 1000 Figure 1: Generating Prefix Codes Using Huffman Coding

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

The Database Management Systems

Authors: Patricia Ward, George A Dafoulas

1st Edition

1844804526, 978-1844804528

More Books

Students also viewed these Databases questions

Question

Define nudges.

Answered: 1 week ago