#include<bits/stdc++.h>
#define int long long
#define ld long double
#define fi first
#define se second
#define vll vector<int>
#define pii pair<int,int>
#define pb push_back
#define sz(v) (int)(v).size()
#define inf (int)(1e18)
#define md (int)(998244353)
#define all(v) (v).begin(),(v).end()
#define rep(i,a,b) for(int i=a;i<b;++i)
using namespace std;

const int M = 1e6 + 10;

int ans[M],d[M];

int32_t main(){
    ios_base::sync_with_stdio(false);
    cin.tie(0);
   	
   	rep(i,1,M)for(int j=i;j<M;j+=i) d[j]++;
   	
   	ans[1]=1,ans[2]=3;
   	int sum=4;
   	rep(i,3,M) {
   		ans[i]=(sum+d[i])%md;
   		(sum+=ans[i])%=md;
   	}
   	int n;
   	cin>>n;
   	cout<<ans[n];
   	
    return 0;
}