Skip to content

Commit

Permalink
[docs] fix typo in knapsack.jl (#3792)
Browse files Browse the repository at this point in the history
  • Loading branch information
LilithHafner authored Jul 30, 2024
1 parent 58e8e55 commit 72e33cb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/src/tutorials/linear/knapsack.jl
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ function solve_knapsack_problem(;
println(", c[$i] / w[$i] = ", profit[i] / weight[i])
end
chosen_items = [i for i in 1:n if value(x[i]) > 0.5]
return return chosen_items
return chosen_items
end

solve_knapsack_problem(; profit = profit, weight = weight, capacity = capacity)
Expand Down

0 comments on commit 72e33cb

Please sign in to comment.