answersLogoWhite

0

//Written in C++. ALFRED OMONDI ORIMBO (orimbo@gmail.com)

# include

# include

using namespace std;

void main()

{

double s,a,b,c,area;

cout<<"type a value for first side of triangle: ";

cin>>a;

cout<<"\ntype a value for second side of triangle: ";

cin>>b;

cout<<"\ntype a value for third side of triangle: ";

cin>>c;

s=(a+b+c)/2;

area = sqrt(s*(s-a)*(s-b)*(s-c));

cout<<"\narea = "<

}

User Avatar

Wiki User

12y ago

What else can I help you with?

Related Questions

How do you write a qbasic program to find area and circumerence of a circle?

Write a program that calculates the area of a triangle in QBASIC


C program to find area and perimeter of triangle?

To find the area and perimeter of a triangle in a C program, you would first need to input the three sides of the triangle. Then, you can calculate the perimeter by adding the three sides together. Next, you can calculate the semi-perimeter by dividing the perimeter by 2. Finally, you can use Heron's formula to calculate the area of the triangle using the semi-perimeter and the three sides. The C program would involve taking user input, performing the necessary calculations, and outputting the results.


What are the answers for Programming logic and design chapter 6?

program calculates


How do you write a c program which calculates the value of money at the end of each year of investment?

Reference:cprogramming-bd.com/c_page3.aspx#calculates the value of money


Using while loop write a program which calculates the product of digits from 1 to 5 and also show these nos vertically?

Using while loop, write a program which calculates the product of digits from 1 to 5 and also show these no's vertically.


Is a program with no input an incorrect program?

No, as long as it calculates something, displays something, or otherwise has an output that benefits the user, it is a program. It could be a program that makes a random number, or a program that tells the user a joke from a database.


Was there a program called the triangle?

yea


Using a computer how do you create a program that calculates the circumference and area of a circle?

a circle has an area of 36pie square centimeters what is the circumference ?


How do you write a program that calculates the sum of the matrix elements given numbers?

ring me and ill explain - 086 22222222222222227 ring me


What does the computer program Md5sum do?

Md5sum is a program that verifies and calculates 128-bit MD5 hashes. The MD5 checksum is seen as the compact digital fingerprint that is unique to each file.


Which application software calculates numbers such as a teachers grade book program?

Microsoft office excel you can use for any kind of calculations


Program to calculate area of triangle?

You don't need a program; the formula is b*h/2.