test/cpv/library-checker-enumerative_combinatorics/stirling_number_of_the_second_kind_small_p_large_n.mintd-bd.poly_anymod-pmtt.factorial-factl_helper.cpp
| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | #define AUTO_GENERATED | ||
| 2 | // competitive-verifier: PROBLEM https://judge.yosupo.jp/problem/stirling_number_of_the_second_kind_small_p_large_n | ||
| 3 | #include "../../../src/comb/stirling2_smallp/lib.hpp" | ||
| 4 | |||
| 5 | using namespace tifa_libs; | ||
| 6 | CEXP u32 MOD = 998244353; | ||
| 7 | |||
| 8 | #include "../../../src/fps/ds/mtt/lib.hpp" | ||
| 9 | #include "../../../src/math/ds/mint/bd/lib.hpp" | ||
| 10 | #include "../../../src/math/fact/helper_l/lib.hpp" | ||
| 11 | |||
| 12 | using namespace tifa_libs; | ||
| 13 | using mint = mint_bd<__LINE__>; | ||
| 14 | using namespace tifa_libs; | ||
| 15 | using poly = polymtt<mint>; | ||
| 16 | using namespace tifa_libs; | ||
| 17 | using fact_t = factl_helper<poly>; | ||
| 18 | |||
| 19 | 20 | int main() { | |
| 20 | 20 | mint::set_mod(MOD); | |
| 21 |
1/2✓ Branch 2 taken 20 times.
✗ Branch 3 not taken.
|
20 | std::cin.tie(nullptr)->std::ios::sync_with_stdio(false); |
| 22 | u32 t, mod; | ||
| 23 |
2/4✓ Branch 1 taken 20 times.
✗ Branch 2 not taken.
✓ Branch 4 taken 20 times.
✗ Branch 5 not taken.
|
20 | std::cin >> t >> mod; |
| 24 | 20 | mint::set_mod(mod); | |
| 25 | 20 | tifa_libs::stirling2<mint, fact_t> S; | |
| 26 |
2/2✓ Branch 0 taken 3600016 times.
✓ Branch 1 taken 20 times.
|
3600036 | while (t--) { |
| 27 | u64 n, k; | ||
| 28 |
2/4✓ Branch 1 taken 3600016 times.
✗ Branch 2 not taken.
✓ Branch 4 taken 3600016 times.
✗ Branch 5 not taken.
|
3600016 | std::cin >> n >> k; |
| 29 |
1/2✓ Branch 3 taken 3600016 times.
✗ Branch 4 not taken.
|
3600016 | std::cout << S(n, k) << '\n'; |
| 30 | } | ||
| 31 | 20 | return 0; | |
| 32 | 20 | } | |
| 33 |