Question 1
A manager has 4 tasks to complete over 8 working hours. The task details are:
- Report: Priority High, Duration 3 hours, Deadline 5 hours
- Email: Priority Low, Duration 1 hours, Deadline 6 hours
- Presentation: Priority High, Duration 2 hours, Deadline 4 hours
- Analysis: Priority Medium, Duration 2 hours, Deadline 7 hours
If tasks are scheduled based on priority first and deadline second, which task should be completed first?
Step-by-step solution:
Priority-Deadline Scheduling Algorithm:
1. Assign priority weights:
- High = 3, Medium = 2, Low = 1
2. Create priority-deadline table:
Task | Priority | Deadline | Duration
--------------|----------|----------|----------
Report | High | 5 | 3
Email | Low | 6 | 1
Presentation | High | 4 | 2
Analysis | Medium | 7 | 2
3. Sorting criteria:
- Primary: Highest priority first
- Secondary: Earliest deadline (if priority is same)
4. Sorted order:
1. Presentation (Priority: High, Deadline: 4)
2. Report (Priority: High, Deadline: 5)
3. Analysis (Priority: Medium, Deadline: 7)
4. Email (Priority: Low, Deadline: 6)
Answer: Presentation should be completed first
Key Strategy: Sort by priority first (descending), then by deadline (ascending) for tasks with equal priority.
Priority-Deadline Scheduling Algorithm:
1. Assign priority weights:
- High = 3, Medium = 2, Low = 1
2. Create priority-deadline table:
Task | Priority | Deadline | Duration
--------------|----------|----------|----------
Report | High | 5 | 3
Email | Low | 6 | 1
Presentation | High | 4 | 2
Analysis | Medium | 7 | 2
3. Sorting criteria:
- Primary: Highest priority first
- Secondary: Earliest deadline (if priority is same)
4. Sorted order:
1. Presentation (Priority: High, Deadline: 4)
2. Report (Priority: High, Deadline: 5)
3. Analysis (Priority: Medium, Deadline: 7)
4. Email (Priority: Low, Deadline: 6)
Answer: Presentation should be completed first
Key Strategy: Sort by priority first (descending), then by deadline (ascending) for tasks with equal priority.