Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main(){
- int aux,num3,in,num2,n,x;
- cin>>x;
- num2=x;
- while(x>0){
- aux=x%10;
- num3=num3+aux*in;
- x=x/10;
- in=in*10;
- }
- cout<<num3<<" "<<num2;
- if(num3==num2 && num2>=1){
- return true;
- }else return false;
- }
Advertisement
Add Comment
Please, Sign In to add comment