probably made it a bit faster

This commit is contained in:
Acvaxoort 2023-12-13 01:42:41 +01:00
parent ba7b8521cd
commit b5943d5ce5

View File

@ -117,10 +117,10 @@ fn choose(n: u64, k: u64) -> u64 {
fn count_options_in_uncertain(length_uncertain: u64, sum_broken: u64, num_broken: u64) -> u64 {
let slots = length_uncertain - sum_broken + 1;
// if slots == 0 || num_broken == 0 {
// return 1;
// }
// slots choose num_broken
if slots == 0 || num_broken == 0 {
return 1;
}
choose(slots, num_broken)
}