Reduced to 200 random tests.
Closing this issues as these solutions are ok for the scope of this kata.
Added sample tests for > and refined the assertion messages.
c > b && b > a && a > c -> that test should be in the sample tests too, otherwise an user could fail on that one in the random tests without any idea that he's not failing on a < b && b < c && c < a, which has the very same assertion message.
c > b && b > a && a > c
a < b && b < c && c < a
You have exactly one way to give out 0 change: give out 0 coins. This is consistent with the binomial coefficient in mathmatics, which gives n over 0 = 1 (i.e. you have 1 possiblity to choose 0 elements from n).
n over 0 = 1
What Hobovsky meant was to use collect(Collectors.joining(", ")) instead of reduce( ... concat()).
reduce( ... concat())
Thanks, i will remeber it for future reference. Fixed
You can replace Rand rand = new Random() by ThreadLocalRandom rand = ThreadLocalRandom.current() and use this one. Also you can remove the import to java.util.Random then.
Rand rand = new Random()
ThreadLocalRandom rand = ThreadLocalRandom.current()
r in (0, 10)
o in (-5, 8)
w in (1, 10)