Description Usage Arguments Value
View source: R/greedy_knapsack.R
greedy_knapsack_c function
1 | greedy_knapsack(x, W, fast = FALSE)
|
x |
A data.frame with two variables v (values) and w (weights) |
W |
The maximum knapsack size |
fast |
=FALSE set to TRUE if you want c++ code |
A list of the maximum value in the knapsack and the elements choosen to be in the knapsack
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.