#include<stdio.h>
int main()
{
int d,a,b;
scanf("%d",&a);
scanf("%d",&b);
d=a-b;
int temp;
int j,i=0,rem,p[10000];
while(d>0)
{
rem=d%10;
p[i]=rem;
i++;
d=d/10;
}
for(j=0;j<i/2;j++)
{
temp=p[j];
p[j]=p[i-(1+j)];
p[i-(1+j)]=temp;
}
for(j=0;j<i;j++)
{
printf("%d",p[j]);
}
printf("\n");
if(p[0]>1)
p[0]=p[0]-1;
else
p[0]=p[0]+2;
for(j=0;j<i;j++)
{
printf("%d",p[j]);
}
return 0;
}
sorry I got it…!! I got it where I was doing mistake.