#include <bits/stdc++.h>
using namespace std;
int n, m, t = 0;
int main(){
ios::sync_with_stdio(false); cin.tie(0); cout.tie(0);
cin >> n >> m;
for (int i = n; i <= m; i++)
{
int s = 1;
for (int j = 2; j * j < i; j++)
{
if (i % j != 0)
{
s = 0;
break;
}
}
if (s == 1) t++;
}
cout << t;
return 0;
}
本人蒟蒻