GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 100.0% 15 / 0 / 15
Functions: 100.0% 2 / 0 / 2
Branches: 71.4% 10 / 0 / 14

test/cpv_local/nt/lsieve2.loj6680.s30.cpp
Line Branch Exec Source
1 // competitive-verifier: LOCALCASE test/cpv_local/_data/loj/6680
2
3 // clang-format off
4 #include "../../../src/util/op/pair/lib.hpp"
5 // clang-format on
6
7 #include "../../../src/math/ds/mint/ms/lib.hpp"
8 #include "../../../src/nt/lsieve/impl2/lib.hpp"
9
10 using namespace tifa_libs;
11 using std::cin, std::cout;
12 using mint = mint_ms<998244353>;
13
14 20 int main() {
15 u32 n;
16
1/2
✓ Branch 1 taken 20 times.
✗ Branch 2 not taken.
20 cin >> n;
17 20 lsieve2 ls(n);
18 20 ptt<mint> lst;
19 6257470 vecpt<mint> g = ls.run([&](u32 p, u32 e) {
20
2/2
✓ Branch 0 taken 6250874 times.
✓ Branch 1 taken 6596 times.
6257470 if (e == 1) return lst = ptt<mint>(p + (p ^ 1), 1 + (p ^ 1));
21 6596 else return lst = ptt<mint>((lst.first * p + (p ^ e)), (lst.second + (p ^ e)));
22 },
23 20 ptt<mint>{1, 1});
24
25
1/2
✓ Branch 1 taken 20 times.
✗ Branch 2 not taken.
20 vec<mint> f(n + 1);
26 20 f[1] = 1;
27
2/2
✓ Branch 8 taken 92568043 times.
✓ Branch 9 taken 20 times.
92568063 flt_ (u32, i, 2, n + 1) f[i] = f[i - 1] + g[i].first + g[i].first - g[i].second;
28 20 u64 ans = f[1].val();
29
2/2
✓ Branch 2 taken 92568043 times.
✓ Branch 3 taken 20 times.
92568063 flt_ (u32, i, 2, n + 1) ans ^= f[i].val();
30
2/4
✓ Branch 1 taken 20 times.
✗ Branch 2 not taken.
✓ Branch 4 taken 20 times.
✗ Branch 5 not taken.
20 cout << ans << '\n';
31 20 }
32