Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- int a,b,c,d,i,tot,flg=0;
- cin >> a;
- for(i=1; i<=9; i++)
- {
- if(a%i==0)
- {
- b=i;
- d = a/i;
- flg ++;
- }
- tot = d*10+b;
- }
- if(flg==0 || tot>=100)
- cout << "-1" << endl;
- else
- cout << tot << endl;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement