Program to calculate Area of Square.
A program that get hight and width from userand calculate Area of a Square:
formula for area
using namespace std;#include<iostream>
#include<conio.h>
int main()
{
float hight,width,area;
cout<<"Enter Hight:";
cin>>hight;
cout<<"Enter Width:";
cin>>width;
area = hight * width;
cout<<"Area of Square="<<area;
getch();
return 0;
}
we can also make program that use:
- triangle formula
- perimeter of square
- volume formula
- etc...
Program to calculate Area of Square.
Reviewed by Alpha
on
3/05/2017 01:27:00 pm
Rating:
No comments: