#include<bits/stdc++.h> using namespace std; int main(){ int a,b; cin>>a>>b; for(int k=1;k<=a;k++){ if(k%b==0){ cout<<k<<" "; } } return 0; }