Help For UVa — 624 ( CD )

Revision en3, by ssavi, 2016-08-06 10:54:21

UPD: SOLVED

Hello .

Problem: https://uva.onlinejudge.org/external/6/p624.pdf

I am trying to solve this Problem from today morning . I got WA for several times. I am trying to solve it using 0-1 Knapsack Technique .

In this problem I need to print the items those I have entered into the Sack. But I have no idea how to do it. To solve this problem I wrote a function named path_print to print the Items. I know the error is in that function . That's why I am getting Wrong Answer .

My Code: http://pastebin.ubuntu.com/22295411/

Now can someone please help me to give an idea about How to print the KnapSack Items according to My code.

It'll be a great favor .

Thanks in Advance .

Tags knapsack

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en3 English ssavi 2016-08-06 10:54:21 19 Tiny change: 'Hello .\n\' -> '**UPD: SOLVED**\n\nHello .\n\'
en2 English ssavi 2016-08-05 16:55:17 11 Tiny change: ' named **pKnapsack ath_print*' -> ' named **path_print*'
en1 English ssavi 2016-08-05 16:54:42 739 Initial revision (published)