adsense

Hii, welcome to my site. My name is Om prakash kartik. This blog helps you to learn programming languages concepts.

Program to calculate area of rectangle in C


Program to calculate area of rectangle in C



//Program to calculate area of rectangle in C
#include<stdio.h>
 int main()
  {
    float b,l,area;
    printf("Enter the length of rectangle :- ");
    scanf("%f",&l);
    printf("Enter the breadth of rectangle :- ");
    scanf("%f",&b);
    //Area of rectangle = length * breadth
    area = l * b;
    printf("Area of rectangle = %.2f",area);
    return 0;
  }
Output :-




Video

Post a Comment

0 Comments