Strawberrry
Forum Veteran
- Joined
- Aug 2, 2016
- Posts
- 1,598
- Solutions
- 4
- Reaction
- 633
- Points
- 524
Good afternoon! Thank you for taking time to read this thread, I wanna know the flowchart of this code if you know It would be nice if you tell me about it
/* Just type the name of the symbol and its insides for example "Circle - Start" */
/* Just type the name of the symbol and its insides for example "Circle - Start" */
C:
#include <stdio.h>
int main()
{
float radius, diameter, circumference, area;
/*
* Input radius of circle from user
*/
printf("Enter radius of circle: ");
scanf("%f", &radius);
/*
* Calculate diameter, circumference and area
*/
diameter = 2 * radius;
circumference = 2 * 3.14 * radius;
area = 3.14 * (radius * radius);
/*
* Print all results
*/
printf("Diameter of circle = %.2f units \n", diameter);
printf("Circumference of circle = %.2f units \n", circumference);
printf("Area of circle = %.2f sq. units ", area);
return 0;
}