#include<bits/stdc++.h>
using namespace std;
#define N 1000010
const int mod=998244353;
typedef long long ll;
inline ll read(){
	ll x=0,f=1;
	char c=getchar();
	while(c<'0'||c>'9'){
		if(c=='-')f=-1;
		c=getchar();
	}
	while(c>='0'&&c<='9'){
		x=(x<<1)+(x<<3)+c-'0';
		c=getchar();
	}
	return x*f;
}
int n,dp[N],s[N];
int main(){
	n=read();
	for(int i=1;i<=n;++i){
		for(int j=i;j<=n;j+=i){
			++dp[j];
		}	
	}
	for(int i=1;i<=n;++i){
		dp[i]=(dp[i]+s[i-1])%mod;
		s[i]=(s[i-1]+dp[i])%mod;
	}
	printf("%d\n",dp[n]);
	return 0;
}

