#include using namespace std; using ll = long long; #define REP(i, n) for (int i = 0; i < (n); i++) template using V = vector; template ostream &operator<<(ostream &os, const V &v) { os << "[ "; for (auto &vi: v) os << vi << ", "; return os << "]"; } template ostream &operator<<(ostream &os, const pair &p) { return os << "{ " << p.first << ", " << p.second << "}"; } #ifdef LOCAL #define show(x) cerr << __LINE__ << " : " << #x << " = " << x << endl; #else #define show(x) true #endif using uint = unsigned int; using ull = unsigned long long; template struct Modint { using M = Modint; const static M G; uint v; Modint(ll val = 0) { set_v(val % MD + MD); } M& set_v(uint val) { v = (val < MD) ? val : val - MD; return *this; } explicit operator bool() const { return v != 0; } M operator-() const { return M() - *this; } M operator+(const M& r) const { return M().set_v(v + r.v); } M operator-(const M& r) const { return M().set_v(v + MD - r.v); } M operator*(const M& r) const { return M().set_v(ull(v) * r.v % MD); } M operator/(const M& r) const { return *this * r.inv(); } M& operator+=(const M& r) { return *this = *this + r; } M& operator-=(const M& r) { return *this = *this - r; } M& operator*=(const M& r) { return *this = *this * r; } M& operator/=(const M& r) { return *this = *this / r; } bool operator==(const M& r) const { return v == r.v; } M pow(ll n) const { M x = *this, r = 1; while (n) { if (n & 1) r *= x; x *= x; n >>= 1; } return r; } M inv() const { return pow(MD - 2); } friend ostream& operator<<(ostream& os, const M& r) { return os << r.v; } }; using mint = Modint<998244353>; int main() { long long N; cin >> N; vector div; for (long long d = 1; d * d <= N; d++) { if (N % d == 0) { div.push_back(d); if (d * d != N) div.push_back(N / d); } } sort(div.begin(), div.end()); show(div); int M = int(div.size()); vector dp(M); dp[0] = 1; REP(i, M) { REP(j, M) { long long nx = lcm(div[i], div[j]); int ind = lower_bound(div.begin(), div.end(), nx) - div.begin(); if (i >= ind or ind >= M or div[ind] != nx) continue; dp[ind] += dp[i]; } } cout << dp.back() << '\n'; return 0; }