#include using namespace std; #define int long long #define rep(i,n) for(int i=0;i #define len(s) (int)s.size() #define pb push_back template inline bool chmin(T &a, T b){ if(a>b){a=b;return true;} return false; } template inline bool chmax(T &a, T b){ if(apar,size; int find(int x){ return (par[x]==x?x:par[x]=find(par[x])); } void merge(int x,int y){ x=find(x);y=find(y); if(x==y)return; if(size[x]>L>>R; int ans=0; UnionFind uf(R-L+1); for(int i=L;i<=R;i++){ for(int j=2;i*j<=R;j++){ uf.merge(i-L,i*j-L); } } rep(i,R-L+1){ ans+=uf.find(i)==i; } cout<