Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

Problem 1: Apply the process of Job Sequencing with

Deadline in the given data:


Task T1 T2 T3 T4 T5 T6 T7 T8 T9 T10
Deadline 9 2 5 7 4 2 5 7 4 3
Profit 20 12 18 15 5 6 7 10 13 9

Answer the following questions-


1.Show the optimal schedule that gives maximum profit.
= T7, T2, T10, T9, T3, T8, T4, T1

2.Are all the jobs completed in the optimal schedule?


= Tasks are not completed in optimal schedule T6 and T5 could not be completed with
its deadline.

3.What is the maximum earned profit?


= T7+T2+T10+T9+T3+T8+T4+T1
= 7+12+9+13+18+10+15+20
= 104 units

Problem Number 2: Complete the table for fixed and VLC.


Show the process for priority queue. Compute the total
compressed bits of the Fixed code and VLC, and the
compressed saving.
Character a b c d e f g h i j k
Frequency 12 10 9 12 13 5 20 6 13 5 11
Fixed code 0000 0001 0010 0011 0100 0101 0110 0111 1000 1001 1010
( 4 bits)
VLC 001 1100 1011 010 011 11010 111 1010 100 11011 000

You might also like