Greedy Technique: GATE CS Previous Year Questions

Greedy Technique · Algorithms

11 questions · asked in 7 of 27 years (2000–2026)

MCQ 7 · MSQ 1 · NAT 31-mark 6 · 2-mark 5

2000Questions per year2026

Questions 11–11 of 11

Q11GATE 20051 markMCQ−0.33 if wrong
We are given 9 tasks T1, T2... T9. The execution of each task requires one unit of time. We can execute one task at a time. Each task Ti has a profit Pi and a deadline di Profit Pi is earned if the task is completed before the end of the dith unit of time.
Task Profit Deadline T1 15 7 T2 20 2 T3 30 5 T4 18 3 T5 18 4 T6 10 5 T7 23 2 T8 16 7 T9 25 3
Are all tasks completed in the schedule that gives maximum profit?

Keep practising

Topics in Algorithms

All CS topics ›