Computer for SEE and NEB

It is a complete SEE and NEB solution for computer science. It includes Computer Fundamentals, Database (SQL), Programming in C QBASIC, CSS, JavaScript, and PHP for beginners.

Breaking

Post Top Ad

Your Ad Spot

Tuesday, July 12, 2022

C program to find the area and perimeter of a rectangle for SEE and NEB

C program to find the area and perimeter of a rectangle for SEE and NEB



#include<stdio.h>

#include<conio.h>

main()

{

//calculate the area and perimeter of rectangle

int l,b,a,p;

printf("Enter length and breadth\n");

scanf("%d%d",&l,&b);

a=l*b;

p=2*(l+b);

printf("Area=%d\nPerimeter=%d",a,p);

getch();

}


Output:




No comments:

Post a Comment

Post Top Ad

Your Ad Spot

Pages