#include<bits/stdc++.h>
using namespace std;
int m,n,maxn,cmt;
int zhishu(int x)
{
cmt=0;
for(int j=2;j<=sqrt(x);j++)
if(x%j==0)
cmt++;
int cnt=cmt;
cmt=0;
if(cnt==0)return 1;
else return 0;
}
int yinzi(int x)
{
maxn=0;
for(int j=1;j<=x;j++)
{
if(x%j==0)
{
zhishu(j);
}
if(zhishu(j)==1)
maxn=max(maxn,j);
}
int mx=maxn;
maxn=0;
return mx;
}
int main()
{
cin>>m>>n;
for(int i=m;i<=n;i++)
{
if(i<n)
{
cout<<yinzi(i)<<",";
}
else cout<<yinzi(i);
}
return 0;
}