Area of Circle Flowgorithm Flowchart

  • 3 months ago
Area of Circle Flowgorithm Flowchart

www.TestingDocs.com
Transcript
00:00Hi, in this tutorial you will learn how to design a flowchart to compute the area of
00:11circle with radius r.
00:15The mathematical formula for the area of circle is pi star r square.
00:23So pi is a mathematical constant and r is the radius of the given circle.
00:32So in the flowchart we will prompt the user to enter the radius of the circle that is
00:38r.
00:40Launch the flow graph application from the start menu.
00:43Initially you will get two flowchart symbols main and end.
00:49You can design the flowchart by adding the symbols within these two symbols.
00:55So right click on the control line and declare a variable called area.
01:02This denotes the area of the circle and let's declare another variable called radius.
01:11We will specify it as r which is of type real and let's initialize the variables to 0 and
01:26specify the radius r and in the right hand side specify 0.
01:33Similarly give the variable area and specify 0.
01:40Now we are initializing these two variables to 0.
01:46Now let's prompt the user to enter the radius of the circle.
02:09So this will prompt the user to enter the radius of the circle.
02:16Take the user input into the variable r so let's specify r.
02:24Now take an assign symbol and compute the area of the circle.
02:36So to use pi we can specify these two letters which denotes the pi constant in flow algorithm.
02:48So as a convention we will use the capital letter for a constant.
02:54So now specify the variable r.
03:01You can either specify it as again star r to calculus or you can use the exponential
03:08operator carrot symbol and click on ok.
03:22This will compute the radius, the area of the circle and store it in the variable called
03:28area.
03:29Now display the area of the circle.
03:50This will display the area of the circle.
03:57That's it we are done with the flowchart.
04:00Let's test the flowchart by running the flowchart.
04:04Click on the play button, enter the radius of the circle, enter 3.
04:12Now you can see that the area of the circle got displayed in the control window.
04:22That's it and this is the flowchart for calculating the area of the circle.
04:30Thanks for watching.

Recommended