#include using namespace std; typedef long long ll; typedef long double ld; #define REP(i, n) for (int i = 0; i < (n); ++i) #define REPR(i, n) for (int i = n - 1; i >= 0; --i) #define FOR(i, m, n) for (int i = m; i < n; ++i) #define FORR(i, m, n) for (int i = m; i >= n; --i) #define ALL(v) (v).begin(),(v).end() templatebool chmax(T &a, const T &b) { if (abool chmin(T &a, const T &b) { if (b0;k>>=1){ if(k&1){ res=(res*n)%m; } n=(n*n)%m; } return res; } int main(){ cin.tie(0); ios::sync_with_stdio(false); ll n,m;cin >> n >> m; FOR(x,1,m+1){ int u=(n+1)/x,v=(n+1)%x; if(v==0) v=x; cout << pow_mod(u+1,x-v,mod)*pow_mod(u,v-1,mod)%mod*(u-1)%mod << endl; } }