#include <stdio.h> float area(float r); int main() { float radius, AOC; printf("--Area of Circle--\n"); printf("Enter the radius of the circle:"); scanf("%f", &radius); AOC=area(radius); printf("The area of the circle is %.2f", AOC); } float area(float r) { return(3.14159265359*r*r); }
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter