Showing posts with label WAP to SWAP the three digit number. Show all posts
Showing posts with label WAP to SWAP the three digit number. Show all posts

SWAP NUMBERS

WAP to SWAP the three digit number

void main ()

{

int b,r,n,r1,r2;

clrscr ();

printf ("Enter the Value: ");

scanf ("%d",&n);

r=n%10;

n=n/10;

r1=n%10;

n=n/10;

r2=n%10;

n=n/10;

b=(r*100)*(r2*10)+(r2);

printf ("%d%d%d",r,r1,r2);

getch ();

}


Labels