void main()
{ int a,b,c,x,y; /* Define 4 variables */
scanf("%d ",& ampx); /* Enter a three-digit x */
a = x/ 100; /* Calculate one percent of x */
b =(x-a * 100)/ 10; /* Calculate the ten digits of x */
c = x % 10; /* Calculate the single digits of x */
y = c * 100+b * 10+a; /* Calculate the reciprocal */
printf("%d\n ",y); /* Output the inverse number y */
getch();
Returns 0;
}
My college homework, don't worry that A, B and C are not integers, because I define them as plastic. .