RENT — Rent your airplane and make money on SPOJ

Revision en2, by vikasrathee10, 2018-11-02 10:53:43

I am trying to solve the problem RENT — Rent your airplane and make money on SPOJ using simple DP and Linear Search. Sorting the jobs according to their end_time and then using dp[i] to store the max profit that can be earned up to ith job by calculating the max profit that can be earned by including ith job and by excluding ith but I am getting wrong answer. Here is my solution link https://sapphireengine.com/@/gv9ow5

Tags #spoj, #c++, competitive programming

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English vikasrathee10 2018-11-02 10:53:43 2
en1 English vikasrathee10 2018-11-02 10:47:46 479 Initial revision (published)