fork download
  1. #include <stdio.h>
  2.  
  3. int main()
  4. {
  5. float r, area;
  6.  
  7. printf("Enter the radius of the circle: ");
  8. scanf("%f", &r);
  9.  
  10. area = 3.1416 * r * r;
  11.  
  12. printf("Area of the circle = %.2f", area);
  13.  
  14. return 0;
  15. }
Success #stdin #stdout 0.01s 5320KB
stdin
4
stdout
Enter the radius of the circle: Area of the circle = 50.27