what will be the output of following program ?
would this program compile properly ?
#include <stdio.h>
void swap(int **cc,int *dd)
{
int t=**cc;
**cc=*dd;
*dd=t;
}
void exchange(int *cc,int *dd)
{
swap(&cc,dd);
}
int main(void)
{
int c=10,d=20;
printf("befor swap c=%d d=%d \n",c,d);
exchange(&c,&d);
printf("after swap c=%d d=%d \n",c,d);
}