Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* TAHMID RAHMAN
- DAMIAN FOREVER
- MATH LOVER
- NEVER GIVE UP
- */
- #include<bits/stdc++.h>
- using namespace std;
- #define pi acos(-1.0)
- #define fastio ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL)
- #define ll long long
- #define pb push_back
- #define fi first
- #define se second
- #define in insert
- #define mp make_pair
- #define GCD(a,b) __gcd(a,b);
- #define endl "\n"
- #define FRU freopen("out.txt","w",stdout)
- #define FRO freopen("in.txt","r",stdin)
- #define INFLL 9223372036854775807
- //Don't hesitate to ask me if you don't understand my code.......Happy coding,Tahmid...;
- int main()
- {
- fastio;
- ll x,y,f,i,c=0;
- cin>>x>>y>>f;
- while(1)
- {
- ll n=x;
- vector<ll>v;
- v.clear();
- for(i=1;i<=sqrt(n);i++)
- {
- if(n%i==0)
- {
- v.pb(i);
- if(i!=(n/i))
- v.pb(n/i);
- }
- }
- if(v.size()==f)
- {
- c++;
- }
- if(x!=y)
- {
- x++;
- }
- else
- break;
- }
- cout<<c<<endl;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement