Q:

Write a C Program to calculate AREA of rectangle

0

Write a C Program to calculate AREA of rectangle. Here’s simple Program to calculate AREA of rectangle in C Programming Language.

All Answers

need an explanation for this answer? contact us directly to get an explanation for this answer

Below is the source code for C Program to calculate AREA of a rectangle which is successfully compiled and run on Windows System to produce desired output as shown below :

SOURCE CODE : :

/*  C Program to calculate AREA of a rectangle  */

#include<stdio.h>
#include<conio.h>

int main()
{
  int l,b;
  int area;
  printf("Enter the length of the rectangle :: ");
  scanf("%d",&l);
  printf("\nEnter the breadth of the rectangle :: ");
  scanf("%d",&b);
  area=l*b;
  printf("\nThe area of a rectangle is %d \n",area);
return 0;
}

OUTPUT : :

Enter the length of the rectangle :: 5

Enter the breadth of the rectangle :: 6

The area of a rectangle is 30

 

Above is the source code for C Program to calculate AREA of rectangle which is successfully compiled and run on Windows System.The Output of the program is shown above .

need an explanation for this answer? contact us directly to get an explanation for this answer

total answers (1)

C Basic Solved Programs – C Programming

This question belongs to these collections

Similar questions


need a help?


find thousands of online teachers now
Write a C program to calculate Gross Salary of an ... >>
<< C Program to find largest number among three numbe...