# Calculate Triangle Area Flowgorithm Example

# Overview

In this tutorial, we will learn to design a flowchart to calculate the triangle area. This Flowgorithm Example uses the below Flowgorithm flowchart symbols:

- Declare
- Assign
- Input
- Output
- Comment

To know more about Flowgorithm flowchart symbols:

https://www.testingdocs.com/flowgorithm-flowchart-symbols/

## Mathematical Formula

Given the base of the triangle and the height of the triangle,

We can calculate the triangle area as follows:

*Triangle Area = 1/2*base*height*

## Program Development

Let’s declare two variables to hold the input values the triangle base and the height of the triangle.

*base**height*

We will compute the area of the triangle. Let’s declare another variable called *area* to hold the computed value of the area of the triangle.

The *Declare* flowchart symbols are used to declare the variables in the flowchart. The data types of the three variables are of the type *Real*.

We will prompt the user to enter the values of the input variables. We use the output flowchart symbols to prompt the user to enter the values of the triangle base and height.

The area computation is done using an *Assign* flowchart symbol.

## Flowgorithm Flowchart

The flowchart to calculate the triangle area given the base and height is as follows:

## Sample Output

Let’s run the flowchart and verify the output.

That’s it. We have created a simple Flowgorithm flowchart to calculate the area of the triangle.

—

**Flowgorithm Tutorials**

Flowgorithm flowchart tutorials on this website:

https://www.testingdocs.com/flowgorithm-flowchart-tutorial/

**Flowgorithm Website**

For more information on the Flowgorithm tool, please visit the official website at: