You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've been using this version of the library and an issue arose, which I believe is minimal work to correct, so here it is:
I use the getNumberOfGeneratedObjects function which uses the simple factorial and not the one with the BigDecimal type, so when in my application I happened to use in the combination(n,k), n=21 and k=0 respectively, it return zero for the denominator. (factorial(21) > max Long).
If instead the Util.combination(n,k) function was using the BigDecimal factorial, and only after the calculation it converted to long type, that would an easy and satisfiable fix for me (^-^)
The text was updated successfully, but these errors were encountered:
Hi @dpaukov ,
I've been using this version of the library and an issue arose, which I believe is minimal work to correct, so here it is:
I use the getNumberOfGeneratedObjects function which uses the simple factorial and not the one with the
BigDecimal
type, so when in my application I happened to use in the combination(n,k), n=21 and k=0 respectively, it return zero for the denominator. (factorial(21) > max Long).If instead the
Util.combination(n,k)
function was using the BigDecimal factorial, and only after the calculation it converted to long type, that would an easy and satisfiable fix for me (^-^)The text was updated successfully, but these errors were encountered: