CONCLUSION

From these program that be discus we can to a conclusion

1.if we want that the value of an actual argument should not get change in the function being called pass the actual argument by value.

2.if we want that the value of an actual argument should get change in the function being called pass the actual argument by reference.

3.if a function is to be made to return more then one value at atime then return these values indirectly by using call by reference.

Output

Inside main function a address 1371244704

Inside main function b address 1371244708

Inside swap function a address 1371244704

Inside swap function b address 1371244708

 

#include<stdio.h>

void area(int r,float*a,float*r)

{

  *a=3.14*r*r;

  *p=2*3.14*r;

}

int main()

{

  int radius;

  float area, perimeter;

  printf(“enter radius of circle”);

  scanf(“%d”, &radius);

  area(radius, &area, &perimeter);

  printf(“%f”, area);

  printf(“%f”, perimeter);

  return 0;

}