I haven't ( yet ) solved either of them, so for now I remain unconvinced.

If you get solutions, see if any approach works for both. If so, I'd say they're duplicates. If not, well, ok, but spell out the difference a little more in the descriptions.

Actually, due to the differences in the input range, the solutions (at least mine) to these two problems completely differ, and each solution is not strictly better than the other. As you see, the L and m (the size of the alphabet) in Ver 1 is greater than those in Ver 2, but in Ver 2 n is greater than in Ver 1 instead -- so I don't think they duplicate.

Thanks for correcting me and sorry for my poor English. And IMHO, I think the following statement might be clearer:

Formally, since the probability can always be represented as a rational number p/q, you need to return (q^-1) * p % 998244353, where q^-1 represents the multiplicative inverse of q (modulo 998244353).

For the sake of precision, you shouldn't return the possibility as a double. Instead, you should return (the possibility modulo 998244353). Note that 998244353 is a prime number.

Same as the other kata. "Possibility" is the wrong term. You probably want the multiplicative inverse of the reciprocal of the probability.

This comment is hidden because it contains spoiler information about the solution

No, I didn't gt that notice.

Haskell disappeared

Hi @JohanWiltink, in case you didn't get the notice it looks like this issue is keeping this kata in beta: https://www.codewars.com/kata/5f54b1454c2cc4001a662619/discuss/kotlin#5f5f81e0a8c08b0033c500f4

Edited.

Edited.

I haven't ( yet ) solved either of them, so for now I remain unconvinced.

If you get solutions, see if any approach works for both. If so, I'd say they're duplicates. If not, well, ok, but spell out the difference a little more in the descriptions.

That should do it, yes.

Actually, due to the differences in the input range, the solutions (at least mine) to these two problems completely differ, and each solution is not strictly better than the other. As you see, the

`L`

and`m`

(the size of the alphabet) in Ver 1 is greater than those in Ver 2, but in Ver 2`n`

is greater than in Ver 1 instead -- so I don't think they duplicate.Thanks for correcting me and sorry for my poor English. And IMHO, I think the following statement might be clearer:

How do you think about it?

Decide which of the two versions you want to keep, and unpublish the other. This way, they'll always be duplicates of one another.

Same as the other kata. "Possibility" is the wrong term. You probably want the multiplicative inverse of the reciprocal of the probability.

You don't want "the possibility modulo

`998244353`

". You probably want the multiplicative inverse ( modulo`998244353`

) of`1`

over the probability.Well I'm closing the issue...

Thanks for pointing it out.

## Loading more items...