Saleh127

cf 588B

Jul 18th, 2020
129
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.48 KB | None | 0 0
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3. #define test int t; cin>>t; while (t--)
  4. #define ll long long int
  5. #define fellow_junior ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0);
  6. int main()
  7. {
  8. fellow_junior
  9. ll a,c,d,e,i,j,k,l;
  10. cin>>a;
  11. c=1;
  12. for(i=2;i*i<=a;i++)
  13. {
  14. if(a%i==0)
  15. {
  16. c*=i;
  17. while(a%i==0)
  18. {
  19. a/=i;
  20. }
  21. }
  22. }
  23. if(a>1) c*=a;
  24. cout<<c<<endl;
  25. return 0;
  26. }
Advertisement
Add Comment
Please, Sign In to add comment