Write a program to print area of rectangle using function & return its value to main function.

Area of the Rectangle is:- Length*breath



// function for calculating the area of rectangle

int Area(int l,int b)
int a;
return a;

//Driver function
int main()
int length,breath,A;
printf(“Enter length and breath of the Rectanglen”);
A=Area(length,breath); // function calculating
printf(“Area of the Rectangle is: %d”,A);
return 0;


Enter length and breath of the Rectangle
3 4
Area of the Rectangle is: 12

Leave a Reply

Your email address will not be published.