exercism / r

Exercism exercises in R.
https://exercism.org/tracks/r
MIT License
27 stars 38 forks source link

knapsack: add exercise #350

Closed colinleach closed 1 month ago

colinleach commented 2 months ago

The linter is going to complain. Too bad, it's a long URL inside a comment, so live with it.

More seriously, I'm not thrilled with the example.R. I had hoped to vectorize this, but each cell update needs access to the cells above and to the left. Hence needing both matrix indices, hence nested loops. If you have a better idea, please change the file and add yourself as an author.

I've put difficulty 5, copying Python, Julia, C#.

colinleach commented 1 month ago

Thanks for the linter advice. I failed to RTFM!