GATE CSE
First time here? Checkout the FAQ!
x
+2 votes
85 views

Could someone tell me What is the general idea to approach to problems in Dynamic Programming ?

ie. Given a problem How do I start my thinking :P , Im not getting a clue to deal with DP problems .  Making Recursive Equations etc .

Is DP approach is suitable for any problems ?

---------------------------------------------------------------------------------------------------------------------------------------------------

Example Problem

Min-Coin Change is the problem of using the minimum number of coins to make change for a particular amount of cents, n, using a given set of denominations d_{1}\ldots d_{m}.

Given the denominations 1, 5, 10, 20, 25, and wish to make change for 40 cents, the greedy algorithm would give us 25, 10, 5, but the best solution only requires 2 coins - 2 of the 20 cent coins

asked in Algorithms by Loyal (2.5k points)   | 85 views

if you really want more general idea about DP ..you better search competitive programming problems on others sites and their different solution methods. 

These will be useful ...coin change is there in the first pdf.

pdf1

pdf2

pdf3

By examples we get some idea of DP.
mean >?
like we cannot define it directly.

but examining floyd warshall, bellman ford, knapsack we can understand how it works.

Like a small problem able to solve a big problem.

mostly like fibonacci numbers

I just wanted to know a general method to wrte recursion equation .
See here http://gateoverflow.in/8399/gate2015-3_5

I didn't understand how he managed to get the cell  (i)(j)

Please log in or register to answer this question.

Related questions

Top Users Feb 2017
  1. Arjun

    5224 Points

  2. Bikram

    4230 Points

  3. Habibkhan

    3748 Points

  4. Aboveallplayer

    2986 Points

  5. Debashish Deka

    2356 Points

  6. sriv_shubham

    2298 Points

  7. Smriti012

    2142 Points

  8. Arnabi

    2008 Points

  9. sh!va

    1654 Points

  10. mcjoshi

    1628 Points

Monthly Topper: Rs. 500 gift card

20,832 questions
25,989 answers
59,623 comments
22,046 users