Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int nr,d=2,e,x,y;
- cin>>nr;
- x=1;
- y=nr;
- while(nr>1){
- e=0;
- while(nr%d==0){
- nr=nr/d;
- e++;
- }
- for(int i=1;i<=e/2;i++){
- x=x*d;
- }
- d++;
- }
- y=y/(x*x);
- cout<<x<<" "<<y;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement