Skip to content

Commit 422f32b

Browse files
committed
unittest for NTT convolution
1 parent 93faa48 commit 422f32b

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
// competitive-verifier: PROBLEM https://judge.yosupo.jp/problem/convolution_mod_large
2+
3+
#include "../../src/alfred/config/io-sync-off.hpp"
4+
#include "../../src/alfred/math/conv.hpp"
5+
#include <iostream>
6+
7+
int main(int argc, char const *argv[]) {
8+
int n, m;
9+
optimizeIO(), std::cin >> n >> m;
10+
11+
std::vector<m998> f(n), g(m);
12+
for (auto &x : f) std::cin >> x;
13+
for (auto &x : g) std::cin >> x;
14+
15+
auto res = add_conv(f, g);
16+
for (auto &x : res) std::cout << x << ' ';
17+
18+
return 0;
19+
}

0 commit comments

Comments
 (0)