#include<bits/stdc++.h> using namespace std; int main(){ int n;cin>>n;int m;cin>>m; for(int i=m;i<=n;i++){ if(i%m==0){ cout<<i<<" "; } } return 0; }