#include <iostream> #include <algorithm> #include <cmath> #include <string.h> #include <vector> using namespace std; const int mod = 998244353; #define ll long long ll quick_mi(ll a, ll b) { ll ans = 1; while (b) { if (b & 1) ans = ans * a; a = a * a; b >>= 1;...