Welcome![Sign In][Sign Up]
Location:
Downloads SourceCode Mathimatics-Numerical algorithms matlab
Title: 0 Download
 Description: Species of a given n items and a backpack, the weight of item i is Wi, the value of vi, was packet capacity is C, should be how to choose a package of items to be loaded, the backpack load in the largest total value of goods? For each item i, there are only two options, loaded or not loaded. Input: the first line of the two positive integer n (the number of items) and C (capacity) of the second line of n positive integer n, that the value of the third line of n positive integer n, that the weight of output: the total value of the first line of the second line, said n number of (0/1), 0 that the items do not load, that load 1 for example, enter: 5,106,354,622 6 5 4 output 15 1 1 0 0 1
 Downloaders recently: [More information of uploader cjtc1989]
 To Search:
  • [knapback] - Knapsack problem of the optimal parallel
  • [01pack] - Using dynamic programming, greedy algori
File list (Check if you may need any files):
0-1背包问题.cpp
    

CodeBus www.codebus.net