INCREMENTAL / DECREMENTAL
WAP TO ADD 1 & SUBTRACT 1 FROM VALUE OF A & B
(INCREMENTAL & DECREMENTAL OPERATORS)
void main ()
{
int a,b;
clrscr();
printf ("Enter A: ");
scanf ("%d",&a);
printf ("Enter B: ");
scanf ("%d",&b);
a++;
b--;
printf ("\nA is %d",a);
printf ("\nB is %d",b);
getch ();
}
No comments:
Post a Comment