Closed remysucre closed 3 years ago
When calling sum on an empty vector, I got the panic from here:
sum
https://github.com/jcavat/rust-lp-modeler/blob/ca7a3cd6ac30ed715a900c5049bc320f6328ad1d/src/dsl/variables.rs#L451
why can't we return 0 when the vector is empty?
You are absolutely right ! I need to fix this
When calling
sum
on an empty vector, I got the panic from here:https://github.com/jcavat/rust-lp-modeler/blob/ca7a3cd6ac30ed715a900c5049bc320f6328ad1d/src/dsl/variables.rs#L451
why can't we return 0 when the vector is empty?